// substring(int begin, int end) String n = "hello there general kenobi"; System.out.println(n.substring(6, 11)); // -> "there"