Hello all , String s = "abc";
String s2 = new String("abc");
if(s==s2) // this is true
then
String s = "abc";
String s2 = new StringBuffer("abc").toString();
if(s==s2) // this condition will be false
What is the difference between this two codes.
Anyone knows the core reason behind this can put the comment here.
Thanks
Chetan Dhumane
Monday, February 16, 2009
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment