1.string.indexOf(str);
Find the index specified string in string of the first occurrence. Return -1 not found.
String str1="012345";
String str2="23";
System.out.println( str1.indexOf(str2) );//2
2.string。indexOf(string str,int index);
Starts at index index position, find the index position in the string str in.
String str1="012345012345";
String str2="23";
System.out.println( str1.indexOf(str2,5) );//8