ToB企服应用市场:ToB评测及商务社交产业平台

标题: [AcWing 1052] 设计密码 [打印本页]

作者: 滴水恩情    时间: 2022-8-9 14:47
标题: [AcWing 1052] 设计密码


KMP + 状态机

点击查看代码[code]#include#include#include#includeusing namespace std;const int N = 60;const int mod = 1e9 + 7;int n;char str[N];int ne[N];int f[N][N];int main(){    cin >> n >> str + 1;    int m = strlen(str + 1);    for (int i = 2, j = 0; i




欢迎光临 ToB企服应用市场:ToB评测及商务社交产业平台 (https://dis.qidao123.com/) Powered by Discuz! X3.4