It is also possible to use strvariable.equalsIgnoreCase(input) and it will compare the two strings while ignoring the difference between upper case and lower case letters. So in this method A==a and B==b etc. But besides that there isn't any other method that I am aware of.
JamesCherrill: actually, an int would change the "05" to 5.
Cakka: 5 == 05
compareTo won't give any result for that, since you are not using the method. it also depends on whether we are talking about the String class or a class you wrote yourself with it's own implementation of compareTo.
anyway, compareTo will never return true. it will return an int.