KMP: http://blog.csdn.net/v_july_v/article/details/7041827 Sunday:http://blog.csdn.net/q547550831/article/details/51860017