字串查找 Method indexof Method lastIndexof B c is located at index 2 a'is located at index 13 自学示例: s' is located at index-1 Last 'c is located at index 15 StringIndexMethods.java Last ' a'is located at index 13 Last'$ is located at index-1 def is located at index 3 denis located at index 16 hello"is located at index.1 Last"def is located at index 16 Last"def is located at index 16 Last"hello"is located at index-1 2021/2/24 北京理工大学计算机系2021/2/24 北京理工大学计算机系 12 字串查找 ◼ Method indexOf ◼ Method lastIndexOf ◼ 自学示例: StringIndexMethods.java