How the subString() function of String class works
Joined: Apr 15, 2008
please see the following code.
I know that line 3 will still point to "Monday" and have a new String object with the offset and count set to 0,3.
The line 5 will create a new String "Mon" in string pool and point to it.
But not sure what about line 6 whether it will behave like line 3 or line 5.
If i am wrong for line 2 or 4 also please correct..