Tuesday, April 23, 2013

Selenium : To find the length of the string withouth using "Length " function

 To find the length of the string withouth using "Length " function



import javax.swing.JOptionPane;
import org.apache.commons.lang3.StringUtils;

public class Len_of_string
{

 public static void main(String[] args)
 {
  String sStr= JOptionPane.showInputDialog("enter string");
  char[] sArr=sStr.toCharArray();
  System.out.print(sArr.length);
 }

}

No comments:

Post a Comment