Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

这个题可以用AC自动机做吗。。

Posted by kkkwjx at 2014-04-25 18:21:03 on Problem 3450
把第一个串的所有子串组织成AC自动机,然后对后面的n-1个串挨个匹配。最后统计在n-1个串中都成功匹配的子串,选择符合题意的那个。。
感觉这样做要比KMP暴力复杂度要低,但是我写的超时了。。

Followed by:

Post your reply here:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator