cpp implementation of Implement strStr