The answer is 3
"Hello" is the 1st object
"Bill" is another object.
And the result of s1+"Bill" is another object.
so in total 3 objects will be created.
Remember Anju! String Objects in
java are immutable. You cannot change the content of a string object in anyway.
Siva