Computer Science, asked by nonetheless, 2 months ago

example of String literals in java​

Answers

Answered by tusisah
2

Explanation:

example: String s=new String(“Welcome”); It creates two objects (in String pool and in heap) and one reference variable where the variable 's' will refer to the object in the heap.

Similar questions