http://acm.hdu.edu.cn/showproblem.php?pid=3518&PHPSESSID=g0h919dbqkacgvf9jkqj01vru6

算法1:字符串万金油
http://acm.hust.edu.cn/vjudge/problem/viewSource.action?id=1563128
O(n2) 650ms

算法2:后缀三姐妹
2-1. 三妹

http://blog.csdn.net/acm_cxlove/article/details/7948285
http://acm.hust.edu.cn/vjudge/problem/viewSource.action?id=1563151
O(n2), but 40ms

2-2. 二妹
http://acm.hust.edu.cn/vjudge/problem/viewSource.action?id=1579973
http://blog.csdn.net/cool_fires/article/details/9732475
O(n)

2-3. 大姐
http://blog.csdn.net/prairial_0/article/details/8219976
http://acm.hust.edu.cn/vjudge/problem/viewSource.action?id=1575455
O(n)

Comments

comments powered by Disqus