hi friends,
In the foll. code
1.StringBuffer sb1 = new StringBuffer("Amit");
2.StringBuffer sb2= new StringBuffer("Amit");
3.String ss1 = "Amit";
4.System.out.println(sb1==sb2);
5.System.out.println(sb1.equals(sb2));
6.System.out.println(sb1.equals(ss1));
7.System.out.println("Poddar".substring(3));
shouldn't the 6th line give compile error as equals method is not overriden in stringbuffer class.can anybody please explain.
thanks,
mana