摘要: 一、题目描述给定一个整数,请将该数各个位上数字反转得到一个新数。新数也应满足整数的常见形式,即除非给定的原数为零,否则反转后得到的新数的最高位数字不应为零(参见样例2)。二、输入输入共 1 行,一个整数N。-1,000,000,000 ≤ N≤ 1,000,000,000。三、输出... 阅读全文
posted @ 2016-06-08 00:49 chenximcm 阅读(129) 评论(0) 推荐(0) 编辑
摘要: 一、题目描述In computer science and information theory, a Huffman code is an optimal prefix code algorithm.In this exercise, please use Huffman cod... 阅读全文
posted @ 2016-06-08 00:33 chenximcm 阅读(117) 评论(0) 推荐(0) 编辑
摘要: 一、题目描述In the Fibonacci integer sequence, F0 = 0, F1 = 1, and Fn = Fn-1 + Fn-2 for n ≥ 2. For example, the first ten terms of the Fibonacci se... 阅读全文
posted @ 2016-06-08 00:14 chenximcm 阅读(138) 评论(0) 推荐(0) 编辑