Write an expression that evaluates to true if and only if the string variable s equals the string “end”

Write an expression that evaluates to true if and only if the string variable s equals the string “end”

LANGUAGE: Java

CHALLENGE:

Write an expression that evaluates to true if and only if the string variable s equals the string “end”.

SOLUTION:

(s.equals("end"))

Add comment