摘要: 题目: Once upon a time, there is a special coco-cola store. If you return three empty bottles to the shop,you’ll get a full bottle of coco-cola to drink... 阅读全文
posted @ 2015-07-16 22:15 白一 阅读(554) 评论(0) 推荐(0)
摘要: 题目大意: 把十进制整数转换为十六进制,格式为0x开头,10~15由大写字母A~F表示。Input每行一个整数x,0 2 #include 3 using namespace std; 4 int main() 5 { 6 int n; 7 while (cin >> n) 8 ... 阅读全文
posted @ 2015-07-16 21:46 白一 阅读(2060) 评论(0) 推荐(0)
摘要: 题目大意:Vanya gotncubes. He decided to build a pyramid from them. Vanya wants to build the pyramid as follows: the top level of the pyramid must consist ... 阅读全文
posted @ 2015-07-16 21:28 白一 阅读(564) 评论(0) 推荐(0)
摘要: 题目大意:There is a permutation without two numbers in it, and now you know what numbers the permutation has.Please find the two numbers it lose.InputTher... 阅读全文
posted @ 2015-07-16 20:51 白一 阅读(197) 评论(0) 推荐(0)
摘要: (慢慢看题目,O(∩_∩)O~)Mohammad has recently visitedSwitzerland. As he loves his friends very much, he decided to buy some chocolate for them, but as this fi... 阅读全文
posted @ 2015-07-16 20:26 白一 阅读(168) 评论(0) 推荐(0)
摘要: 题目大意: 把所给的年龄排序输入: 第一行输入一个数,表示给的年龄个数; 第二行输入所给的具体年龄以0作为输出结束标志样例: 53 4 2 1 5输出:把年龄从小到大排序;样例: 1 2 3 4 5分析:利用sort函数就可以把年龄排序源代码: 1 #include 2 #include 3 us... 阅读全文
posted @ 2015-07-16 20:08 白一 阅读(1075) 评论(0) 推荐(0)
摘要: 题目大意:A soldier wants to buywbananas in the shop. He has to paykdollars for the first banana,2kdollars for the second one and so on (in other words, he... 阅读全文
posted @ 2015-07-16 19:44 白一 阅读(363) 评论(0) 推荐(0)