BZOJ 5137: [Usaco2017 Dec]Standing Out from the Herd(广义后缀自动机)

5137: [Usaco2017 Dec]Standing Out from the Herd

先建出广义后缀自动机,再dfs加上每个SAM上“独特”的节点对其所在串的贡献即可

 

0 0 vote
Article Rating
Subscribe
提醒
guest
0 评论
Inline Feedbacks
View all comments