摘要:
题意: You are given a string consisting of parentheses()and[]. A string of this type is said to becorrect:(a)if it is the empty string(b)if A and B are ... 阅读全文
摘要:
题意: You are to find all the two-word compound words in a dictionary. A two-word compound word is aword in the dictionary that is the concatenation of ... 阅读全文
摘要:
题意: Given is an ordered deck of n cards numbered 1to n with card 1 at the top and card n at thebottom.The following operation is performed aslong as t... 阅读全文
摘要:
题意: 对于一个n元组(a1,a2,……an),可以对于每个数求出它和下一个数的差的绝对值,得到一个新的n元组(|a1-a2|,|a2-a3|,……|an-a1|)。重复这个过程,得到的序列称为Ducci序列,例如:(8,11,2,7)—>(3,9,5,1)-->(6,4,4,2)-->(2,0,2... 阅读全文