The method is defined to return an int value. The compiler sees that there could be a possibility of the code getting to the end of the if/else if statements and exiting the method without returning an int value. What if hint = "XXXX"?
Add a return with an int value at the end of the method.
To see what the computer sees print out the value of hint with a println after it is read.
Be sure to add String delimiters before and after the variable so you can see all its characters: System.out.println("hint="+hint+"<");
The equals() method is used to compare String values.
equals() method compares two Strings.
If you have given input High / Low / correct, it only matches with hint variable.
What you have stored in hint variable String ot integer?
If you give any input instead of these 3 like bbb or aaa, it will not execute any of these case,and also return nothing.