题目: Implement strStr(). Returns the index of the first occurrence of needle in haystack, or -1 if needle is not part of haystack. 思路: 题意:判断一个字符串是否包含另外一个 写一个函数判断一个字符串从坐标k,是否相等于另一个,遍历一下,i < a.length() -b.length()+1,b.length() < a.length() - 代码: public…