A String is represented as objects in Java. Accordingly, an object contains values stored in instance variables within the object. An object also contains bodies of cod
Strings are immutable in Java, so when you do a println, a new String is created by the toUpperCase (and later garbage collected).
println
String
toUpperCase