随笔分类 -  后缀自动机SAM

SAM
HDU 4436 str2int (后缀自动机SAM,多串建立)
摘要:str2intTime Limit: 6000/3000 MS (Java/Others)Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 841Accepted Submission(s): 297Problem DescriptionIn this problem, you are given several strings that contain only digits from '0' to '9', inclusive.An example is shown below.1 阅读全文

posted @ 2013-10-11 19:25 kuangbin 阅读(1838) 评论(0) 推荐(0)

SPOJ 1811. Longest Common Substring (LCS,两个字符串的最长公共子串, 后缀自动机SAM)
摘要:1811. Longest Common SubstringProblem code: LCSA string is finite sequence of characters over a non-empty finite set Σ.In this problem, Σ is the set of lowercase letters.Substring, also called factor, is a consecutive sequence of characters occurrences at least once in a string.Now your task is simp 阅读全文

posted @ 2013-09-09 00:23 kuangbin 阅读(2119) 评论(0) 推荐(1)

HDU 4622 Reincarnation (查询一段字符串的不同子串个数,后缀自动机)
摘要:ReincarnationTime Limit: 6000/3000 MS (Java/Others)Memory Limit: 131072/65536 K (Java/Others)Total Submission(s): 843Accepted Submission(s): 283Problem DescriptionNow you are back,and have a task to do:Given you a string s consist of lower-case English letters only,denote f(s) as the number of disti 阅读全文

posted @ 2013-08-06 09:18 kuangbin 阅读(3697) 评论(0) 推荐(0)

导航

JAVASCRIPT: