Wednesday 18 June 2014

length()

public int length()
Returns the length of this string.

class StringLength{
 public static void main(String args[]){
  String s1 = "wxyzabdabdda";
  
  System.out.print("Length Of the String is : ");
  System.out.println(s1.length());
 }
}

Output
Length Of the String is : 12


Prevoius                                                 Next                                                 Home

No comments:

Post a Comment