摘要: DescriptionEvery morning when they are milked, the Farmer John's cows form a rectangular grid that is R (1 11 #include 12 #include 13 #include 14 ... 阅读全文
posted @ 2015-03-12 22:16 TCtower 阅读(311) 评论(0) 推荐(0) 编辑
摘要: DescriptionThe 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-... 阅读全文
posted @ 2015-03-12 20:47 TCtower 阅读(204) 评论(0) 推荐(0) 编辑
摘要: DescriptionGiven 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... 阅读全文
posted @ 2015-03-12 20:12 TCtower 阅读(190) 评论(0) 推荐(0) 编辑
摘要: DescriptionThe French author Georges Perec (1936–1982) once wrote a book, La disparition, without the letter'e'. He was a member of the Oulipo group. ... 阅读全文
posted @ 2015-03-12 20:04 TCtower 阅读(193) 评论(0) 推荐(0) 编辑
摘要: DescriptionN个布丁摆成一行,进行M次操作.每次将某个颜色的布丁全部变成另一种颜色的,然后再询问当前一共有多少段颜色.例如颜色分别为1,2,2,1的四个布丁一共有3段颜色.Input第一行给出N,M表示布丁的个数和好友的操作次数. 第二行N个数A1,A2...An表示第i个布丁的颜色从第三... 阅读全文
posted @ 2015-03-12 19:31 TCtower 阅读(192) 评论(0) 推荐(0) 编辑
摘要: Description在一个忍者的帮派里,一些忍者们被选中派遣给顾客,然后依据自己的工作获取报偿。在这个帮派里,有一名忍者被称之为Master。除了Master以外,每名忍者都有且仅有一个上级。为保密,同时增强忍者们的领导力,所有与他们工作相关的指令总是由上级发送给他的直接下属,而不允许通过其他的方... 阅读全文
posted @ 2015-03-12 16:25 TCtower 阅读(302) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionYaoYao is fond of playing his chains. He has a chain containing n diamonds on it. Diamonds are numbered from 1 to n.At first, the d... 阅读全文
posted @ 2015-03-12 09:54 TCtower 阅读(245) 评论(0) 推荐(0) 编辑