What is the output of the following?
string s1 = "asdf"; string s2 = new String("asdf"); boolean test1 = s1 == s2; boolean test2 = s1.equals(s2); System.out.println(test1 + " " + test2);
E.
In Java, String is a class and not a primitive.
This means it needs to begin with an uppercase letter in the declaration.
The code does not compile, making Option E correct.
If this was fixed, the answer would be Option B.