📅  最后修改于: 2022-03-11 14:52:21.049000             🧑  作者: Mango
String str = "testdemo";
System.out.println("String: "+str);
int index = str.indexOf( 'h' );
System.out.printf("'h' is at index %d\n", index);