

MCQOPTIONS
Saved Bookmarks
1. |
Which two statements are true about wrapper or String classes? 1.If x and y refer to instances of different wrapper classes, then the fragment x.equals(y) will cause a compiler failure. 2.If x and y refer to instances of different wrapper classes, then x == y can sometimes be true. 3.If x and y are String references and if x.equals(y) is true, then x == y is true. 4.If x, y, and z refer to instances of wrapper classes and x.equals(y) is true, and y.equals(z) is true, then z.equals(x) will always be true. 5.If x and y are String references and x == y is true, then y.equals(x) will be true.
|
A. | 1 and 2 |
B. | 2 and 3 |
C. | 3 and 4 |
D. | 4 and 5 |
Answer» E. | |