思路:先求出文本串、模式串所有前缀的散列值,及指数值。通过二分查找遍历最大的前缀。
具体代码参考:
https://github.com/wuli2496/OJ/tree/master/codeforces/101466E%20Text%20Editor
思路:先求出文本串、模式串所有前缀的散列值,及指数值。通过二分查找遍历最大的前缀。
具体代码参考:
https://github.com/wuli2496/OJ/tree/master/codeforces/101466E%20Text%20Editor