What will be the output of the program string x="xyz" x.toupper?
Answers
Answered by
0
output of the program string x="xyz" x.toupper IS xyzabc
BECAUSE
Line 3 creates a new String object referenced by y. This new String object has the value "xyz" because there was no "Y" in the String object referred to by x. Line 4 creates a new String object, appends "abc" to the value "xyz
BECAUSE
Line 3 creates a new String object referenced by y. This new String object has the value "xyz" because there was no "Y" in the String object referred to by x. Line 4 creates a new String object, appends "abc" to the value "xyz
Similar questions