HI all, I came across this question in Whizlabs software. StringBuffer s = new StringBuffer("abcd"); invoking length() of String class didnt give any errors i.e. s.length(); Does anybody know the reason. I thought that it cannot use the methods of String class. Thanks in Advance, Latha
s is a StringBuffer and StringBuffer has a length() method. Where do you see String.length() being called in your example? [ April 11, 2004: Message edited by: Barry Gaunt ]