You're getting an evaluation problem here. The
String + String is being evaluated, then the comparison is done, until you set the precedence grouping differenctly by using the parenthesis where you then get String + Boolean. In
Java's order of precidence String concatenation comes before a comparison, but the parenthesis force the grouping you are looking for.