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

Oracle Certified Foundations Associate Java Certification Questions and Discussion
1Z0-811

Moderator: admin

Post Reply
laura.lang
Posts: 3
Joined: Tue Jan 26, 2021 1:35 am
Contact:

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

Post 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
}

admin
Site Admin
Posts: 10036
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

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

Post 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!
If you like our products and services, please help us by posting your review here.

Post Reply

Who is online

Users browsing this forum: No registered users and 16 guests