UVa12604 Caesar Cipher(kmp)

枚举字符串w可偏移后的字符串w',计算其前缀函数,看加密串s中包含w'的个数,如果为1,说明是满足要求的。

代码参考:

https://github.com/wuli2496/OJ/tree/master/UVa/12604%20Caesar%20Cipher

猜你喜欢

转载自blog.csdn.net/wuli2496/article/details/121592323
今日推荐