SAM 做题记录

1.基本 SAM 能a56爆大奖在线娱乐某个字符串的所有子串,且正好是所有子串。 struct sam{ int p=1,cur=1; struct nd{ int len,lnk; map<int,int> ch; nd(int u=0,int v=0){ len=u,lnk=v; ch.clear(); } }
posted @ 2024-05-10 20:07  yhddd  阅读(2)  评论(0编辑  收藏  举报