摘要:Revenge of FibonacciTime Limit: 10000/5000 MS (Java/Others)Memory Limit: 204800/204800 K (Java/Others)Total Submission(s): 914Accepted Submission(s): 197Problem DescriptionThe well-known Fibonacci sequence is defined as following:Here we regard n as the index of the Fibonacci number F(n).This sequen
阅读全文
摘要:Colored SticksTime Limit: 5000MSMemory Limit: 128000KTotal Submissions: 24748Accepted: 6519DescriptionYou are given a bunch of wooden sticks. Each endpoint of each stick is colored with some color. Is it possible to align the sticks in a straight line such that the colors of the endpoints that touch
阅读全文
摘要:IMMEDIATE DECODABILITYTime Limit: 1000MSMemory Limit: 10000KTotal Submissions: 8895Accepted: 4222DescriptionAn encoding of a set of symbols is said to be immediately decodable if no code for one symbol is the prefix of a code for another symbol. We will assume for this problem that all codes are in
阅读全文
摘要:Hat’s WordsTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 3565Accepted Submission(s): 1355Problem DescriptionA hat’s word is a word in the dictionary that is the concatenation of exactly two other words in the dictionary.You are to find all the ha
阅读全文
摘要:Phone ListTime Limit: 1000MSMemory Limit: 65536KTotal Submissions: 16341Accepted: 5228DescriptionGiven a list of phone numbers, determine if it is consistent in the sense that no number is the prefix of another. Let's say the phone catalogue listed these numbers:Emergency 911Alice 97 625 999Bob
阅读全文
摘要:统计难题Time Limit: 4000/2000 MS (Java/Others)Memory Limit: 131070/65535 K (Java/Others)Total Submission(s): 10295Accepted Submission(s): 4216Problem DescriptionIgnatius最近遇到一个难题,老师交给他很多单词(只有小写字母组成,不会有重复的单词出现),现在老师要他统计出以某个字符串为前缀的单词数量(单词本身也是自己的前缀).Input输入数据的第一部分是一张单词表,每行一个单词,单词的长度不超过10,它们代表的是老师交给Ignatius统
阅读全文