一、题目描述
提交 46.03k 通过 20.66k 时间限制 1.00s 内存限制 125.00MB

二、算法分析说明与代码编写指导



三、AC 代码
总时间:229 ms(C++17 O2)
#include<cstdio>
#include<cstring>
#pragma warning(disable:4996)
template<class _Nty> inline void getnext(const char* const p, _Nty* const Next, const _Nty& lp) {
_Nty i = 1, j = 0; Next[1] = 0