Strings
Lesson 7Author : 🦒
Last Updated : October, 2017
Video Code
String greeting = "Hello";
// indexes: 01234
System.out.println( greeting.length() );
System.out.println( greeting.charAt(0) );
System.out.println( greeting.indexOf("llo") );
System.out.println( greeting.indexOf("z") );
System.out.println( greeting.substring(2) );
System.out.println( greeting.substring(1, 3) );