Computer Science, asked by Anonymous, 11 months ago

What is happening here..plz explain those 2 lines
output-- ABC .but how??..
String s = new String("abc");
System.out.println(s.toUpperCase());

Answers

Answered by Anonymous
0

See here in the second line they are saying .toUpperCase ...upper case means to convert the letter into capital ....so her small letter abc converts to capital letter ABC

U must be thorough with string methods only then u ll understand this


Anonymous: what happens in the 1st line....I know the second line
Anonymous: how can we declare object from String
Similar questions