自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(8)
  • 收藏
  • 关注

原创 Clairewd’s message (KMP)

http://acm.hdu.edu.cn/showproblem.php?pid=4300 Clairewd’s message Problem Description Clairewd is a member of FBI. After several years concealing in BUPT, she intercepted some important m

2013-09-29 14:38:27 576

原创 Count the string (KMP)

http://acm.hdu.edu.cn/showproblem.php?pid=3336 Count the string Problem Description It is well known that AekdyCoin is good at string problems as well as number theory problems. When giv

2013-09-29 12:42:38 452

转载 Milking Grid (二维KMP+矩阵覆盖)

http://poj.org/problem?id=2185 题意:给你一个字符矩阵,求出它的最小覆盖子矩阵,即使得这个子矩阵的无限复制扩张之后的矩阵,能包含原来的矩阵。 即二维的最小覆盖子串。 #include #include #include #include #include using namespace std; char str[10010][100]; int

2013-09-29 12:13:48 887

原创 Cyclic Nacklace (KMP 循环节)

http://acm.hdu.edu.cn/showproblem.php?pid=3746 题意:给你一个字符串,要求将字符串的全部字符最少循环2次需要添加的字符数。 例子: abcabc 已经循环2次,添加数为0 abcac 没有循环2次,添加字符abcac。数目为5. a #include #include #include using namespace std; const

2013-09-29 12:08:07 430

转载 Remember the Word (trie)

https://icpcarchive.ecs.baylor.edu/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=1943 Remember the Word Time Limit:3000MS   Memory Limit:Unknown   64bit IO Form

2013-09-27 15:24:30 590

原创 Power Strings(kmp 重复子串)

http://poj.org/problem?id=2406 Description Given two strings a and b we define a*b to be their concatenation. For example, if a = "abc" and b = "def" then a*b = "abcdef". If we think of concaten

2013-09-26 11:02:53 530

原创 Seek the Name, Seek the Fame(kmp)

The little cat is so famous, that many couples tramp over hill and dale to Byteland, and asked the little cat to give names to their newly-born babies. They seek the name, and at the same time seek th

2013-09-25 23:49:15 590

转载 Simpsons’ Hidden Talents (KMP)

http://acm.hdu.edu.cn/showproblem.php?pid=2594 题意:求出最长的串长度,该串既是s1的前缀又是s2的后缀. 思路:把两个字符串连起来求一下前缀数组next[]即可~当然要用”#”或者其他非小写字母连接起来防止两个字符串真的混起来,比如s1=”a”,s2=”aaaa”这种情况。 代码出处 #include #inclu

2013-09-25 20:09:41 569

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除