Description Viruses are usually bad for your health. How about fighting them with... other viruses? In this problem, you need to find out how to synthesize such good viruses. We have prepared for you a set of strings of the letters A, G, T and C. T…
E. Palisection time limit per test 2 seconds memory limit per test 128 megabytes input standard input output standard output In an English class Nick had nothing to do at all, and remembered about wonderful strings called palindromes. We should remin…
Palindrome subsequence Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 131072/65535 K (Java/Others)Total Submission(s): 4513 Accepted Submission(s): 1935 Problem Description In mathematics, a subsequence is a sequence that can be derived f…
CA loves strings, especially loves the palindrome strings. One day he gets a string, he wants to know how many palindromic substrings in the substring S[l,r] . Attantion, each same palindromic substring can only be counted once. InputFirst line conta…
A string is palindrome, if the string reads the same backward and forward. For example, strings like "a", "aa", "appa", "queryreuq" are all palindromes. For given empty string S, you should process following two que…
Harry and magic string Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 223 Accepted Submission(s): 110 Problem Description Harry got a string T, he wanted to know the number of T's disjoint…
CA Loves Palindromic Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 262144/262144 K (Java/Others) Total Submission(s): 301 Accepted Submission(s): 131 Problem Description CA loves strings, especially loves the palindrome strings. One day…