String substring(int startIndex) Returns the substring, beginning at startIndex of the current string and extending to the end of the current string. : String class « Utility Classes « SCJP
8.7.22.String substring(int startIndex) Returns the substring, beginning at startIndex of the current string and extending to the end of the current string.
public class MainClass{ public static void main(String[] argv){
String s = "this is a test";
System.out.println(s.substring(2));
}
}