Page 1 of 1

About Question com.enthuware.jfcja.v8.2.474 :

Posted: Wed Jan 27, 2021 4:57 am
by laura.lang
I believe this should read "Which of the following options are valid, if added independently?"

This answer is easy because only one is not a proper operator for String class.
However, in the explanation of what is printed. s1 == s2 is only false if this is independent of the previous println s1 = s2

If the lines are added cumulatively,

String s1 = "Hello";
String s2 = "World";
s1 += s2;
System.out.println(s1 = s2); //World
System.out.println(s1 == s2); //true
System.out.println(s1.equals(s2)); //true
}

Re: About Question com.enthuware.jfcja.v8.2.474 :

Posted: Wed Jan 27, 2021 6:30 am
by admin
You are right. The problem statement has been enhanced to make it clear that each option is to be considered independent of others.
thank you for your feedback!