Guest User

Untitled

a guest
Dec 18th, 2018
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 KB | None | 0 0
  1. j += MAX(bmGs[i], bmBc[y[i + j]] - m + 1 + i);
  2.  
  3. #include <algorithm>
  4. #include <string>
  5. #include <functional>
  6.  
  7. int main()
  8. {
  9. std::string haystack = "The quick brown fox jumped over the lazy dog";
  10. std::string needle = "brown";
  11. const auto s = std::boyer_moore_searcher<std::string::iterator>(needle.begin(), needle.end());
  12. const auto it = std::search(haystack.begin(), haystack.end(), s);
  13. return 0;
  14. }
Add Comment
Please, Sign In to add comment