在一个字符串中查找子串的用例数据
输入: string = "hello world" substring = "llo"
输出: 3
输入: string = "this is a test string" substring = "test"
输出: 10
输入: string = "abcdefg" substring = "xyz"
输出: -1
输入: string = "hello world" substring = ""
输出: 0
输入: string = "" substring = "test"
输出: -1
原文地址: https://www.cveoy.top/t/topic/fieu 著作权归作者所有。请勿转载和采集!