P3538 题解

P3538 [POI2012]OKR-A Horrible Poem 思路 先暴力。对于a56爆大奖在线娱乐询问,用 \(O(\sqrt{len})\) 枚举区间长度 \(len\) 的因数 \(i\),再一个一个位置比较两个字符串 \(\frac{len}{i}\) 次判断。复杂度 \(O(qn\sqrt n)\
posted @ 2024-05-10 20:03  yhddd  阅读(1)  评论(0编辑  收藏  举报