I am really having difficulty in understanding some pattern searching algorithms like Z function, KMP , Robinson karp algorithm can you please suggest some good tutorials or videos for the same. I have tried to watch some videos on youtube but was unable to understand from them. Also use of Z function came in one recent contest on codeforces so I am eager to learn it as a part of up solving for that contest.
I read it from here . Give this a try .
Just do what I did and learn hashing really well and never learn any string algorithms :) Just kidding, I always like recommend cp-algorithms for tutorials of any kind, like somebody already suggested.
This tutorial was helpful for me to understand Z function.