摘要: Description The word “the” is the most commonthree-letter word. It evenshows up inside other words, suchas “other” and “mathematics”.Sometimes it hide 阅读全文
posted @ 2016-07-19 16:28 konjak魔芋 阅读(420) 评论(0) 推荐(0) 编辑
摘要: Description If a string is in the form UVU, where U is not empty, and V has exactly L characters, we say UVUis an L-Gap string. For example, abcbabc i 阅读全文
posted @ 2016-07-19 15:41 konjak魔芋 阅读(1081) 评论(0) 推荐(0) 编辑
摘要: The Number of Palindromes Problem Description Now, you are given a string S. We want to know how many distinct substring of S which is palindrome. Inp 阅读全文
posted @ 2016-07-19 09:43 konjak魔芋 阅读(463) 评论(0) 推荐(0) 编辑
摘要: Life Forms Description You may have wondered why most extraterrestrial life forms resemble humans, differing by superficial traits such as height, col 阅读全文
posted @ 2016-07-18 11:01 konjak魔芋 阅读(547) 评论(0) 推荐(0) 编辑
摘要: Long Long Message Description The little cat is majoring in physics in the capital of Byterland. A piece of sad news comes to him these days: his moth 阅读全文
posted @ 2016-07-17 16:32 konjak魔芋 阅读(231) 评论(0) 推荐(0) 编辑
摘要: 怪盗基德的挑战书 Problem Description “在树最美丽的那天,当时间老人再次把大钟平均分开时,我会降临在灯火之城的金字塔前,带走那最珍贵的笑容。”这是怪盗基德盗取巴黎卢浮宫的《蒙娜丽莎的微笑》这幅画时,挑战书上的内容。 但这次,怪盗基德的挑战书上出现了一串串小写字母“aaab sdf 阅读全文
posted @ 2016-07-17 15:46 konjak魔芋 阅读(350) 评论(0) 推荐(0) 编辑
摘要: Common Substrings Description A substring of a string T is defined as: T(i, k)=TiTi+1...Ti+k-1, 1≤i≤i+k-1≤|T|. Given two strings A, B and one integer  阅读全文
posted @ 2016-07-17 14:43 konjak魔芋 阅读(758) 评论(0) 推荐(0) 编辑
摘要: Apocalypse Someday Description The number 666 is considered to be the occult “number of the beast” and is a well used number in all major apocalypse t 阅读全文
posted @ 2016-07-17 10:00 konjak魔芋 阅读(265) 评论(0) 推荐(0) 编辑
摘要: A Plug for UNIX Description You are in charge of setting up the press room for the inaugural meeting of the United Nations Internet eXecutive (UNIX), 阅读全文
posted @ 2016-07-15 14:23 konjak魔芋 阅读(259) 评论(0) 推荐(0) 编辑
摘要: 3530: [Sdoi2014]数数 Description 我们称一个正整数N是幸运数,当且仅当它的十进制表示中不包含数字串集合S中任意一个元素作为其子串。例如当S=(22,333,0233)时,233是幸运数,2333、20233、3223不是幸运数。 给定N和S,计算不大于N的幸运数个数。 我 阅读全文
posted @ 2016-07-14 10:48 konjak魔芋 阅读(343) 评论(0) 推荐(0) 编辑
摘要: 2016-07-13 09:59:42 阅读全文
posted @ 2016-07-13 09:56 konjak魔芋 阅读(162) 评论(0) 推荐(0) 编辑
摘要: Resource Archiver Time Limit: 10000MS Memory Limit: 100000KB 64bit IO Format: %I64d & %I64u Description Great! Your new software is almost finished! T 阅读全文
posted @ 2016-07-13 09:52 konjak魔芋 阅读(703) 评论(0) 推荐(0) 编辑
摘要: Description Given an N × M matrix, your task is to find the number of occurences of an X × Y pattern. InputThe first line contains a single integer t 阅读全文
posted @ 2016-07-12 15:35 konjak魔芋 阅读(612) 评论(1) 推荐(0) 编辑
摘要: 【题意】 某人读论文,一篇论文是由许多单词组成。但他发现一个单词会在论文中出现很多次,现在想知道每个单词分别在论文中出现多少次。 【分析】 个人觉得是用了反fail树的思想,Ans[i]=t[i].cnt+∑Ans[反fail]...不过因为有些节点的反fail会有很多个,存起来不方便。但是AC自动 阅读全文
posted @ 2016-07-12 10:09 konjak魔芋 阅读(337) 评论(0) 推荐(0) 编辑
摘要: 【题意】 给定一些单词,我们定义一篇可读文章至少包含一个这样的单词,求长度为M的可读文章总数。 【分析】 用前几题的方法可以求长度为M的不可读的文章总数Sum,所以我们可以用26^M-Sum来求出可读文章的总数。不过这题的N*Len太大,也就是AC自动机的节点太多,如果用矩阵乘法求解用爆空间,所以我 阅读全文
posted @ 2016-07-12 10:08 konjak魔芋 阅读(280) 评论(0) 推荐(0) 编辑
摘要: Lost's revenge Time Limit: 5000MS Memory Limit: 65535KB 64bit IO Format: %I64d & %I64u Description Lost and AekdyCoin are friends. They always play "n 阅读全文
posted @ 2016-07-12 09:39 konjak魔芋 阅读(653) 评论(0) 推荐(0) 编辑
摘要: Wireless Password Time Limit: 1000MS Memory Limit: 32768KB 64bit IO Format: %I64d & %I64u Description Liyuan lives in a old apartment. One day, he sud 阅读全文
posted @ 2016-07-11 14:01 konjak魔芋 阅读(444) 评论(0) 推荐(0) 编辑
摘要: DNA repair Time Limit: 2000MS Memory Limit: 65536KB 64bit IO Format: %I64d & %I64u Description Biologists finally invent techniques of repairing DNA t 阅读全文
posted @ 2016-07-11 10:03 konjak魔芋 阅读(580) 评论(0) 推荐(0) 编辑
摘要: DNA Sequence Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 14758 Accepted: 5716 Description It's well known that DNA Sequence is a sequen 阅读全文
posted @ 2016-06-23 16:20 konjak魔芋 阅读(364) 评论(0) 推荐(0) 编辑
摘要: Word Puzzles Time Limit: 5000MS Memory Limit: 65536K Total Submissions: 10782 Accepted: 4076 Special Judge Description Word puzzles are usually simple 阅读全文
posted @ 2016-06-18 10:32 konjak魔芋 阅读(322) 评论(0) 推荐(0) 编辑