Java examples for Language Basics:String
Convert String to long
public class Main { public static void main(String[] args) { //declare String object String str = new String("10"); long l = Long.parseLong(str); System.out.println(l);//from w w w. ja v a 2s. c o m } }