Plz guys look at this code carefully.
[code=java]
String a = "abc";
String b = "abc";
String c = new String("abc");
System.out.prin tln(a == b);
System.out.prin tln(a == c);
//and the output is true and false.
[/code]
why not the output is false and false?
plz explain.
kind regards.
dmjpro.
[code=java]
String a = "abc";
String b = "abc";
String c = new String("abc");
System.out.prin tln(a == b);
System.out.prin tln(a == c);
//and the output is true and false.
[/code]
why not the output is false and false?
plz explain.
kind regards.
dmjpro.
Comment