For this Question: You're given a string S of lowercase letters of the english alphabet. Find whether you can choose some characters of the string S in any order to create the string "red".The first and the only line of input contains the string S.

Constraints
1 <= |S| <= 100
All the characters in S are lowercase letters of the english alphabet.Output "Yes" (without quotes) if you can create the string "red", else output "No" (without quotes).Sample Input
damngrey

Sample Output
Yes

Explanation: We choose character at position 6, then position 7, then position 1.

Sample Input
newtonschool

Sample Output
No, I have written this Solution Code: import java.io.*;
import java.util.*;



class Main {
	public static void main (String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		boolean r=false,e=false,d=false;
		for(int i=0;i<str.length();i++){
			char ch = str.charAt(i);
			if(ch=='r')r=true;
			if(ch=='e')e=true;
			if(ch=='d')d=true;
		}
		String ans = (r && e && d)?"Yes":"No";
		System.out.print(ans);
	}
}, In this Programming Language: Java, Now tell me if this Code is compilable or not?