Wednesday, 9 April 2014

StringBufferMethods




class StringMethods
{
public static void main(String[] args)
{
StringBuffer sb=new StringBuffer("hello");
sb.append("java");
sb.insert(5,"---new---");

System.out.println(sb);
System.out.println(sb);
System.out.println(sb.length());
}
}

No comments:

Post a Comment