
进制转化
han_hhh
这个作者很懒,什么都没留下…
展开
-
2进制转化为3进制
总时间限制: 1000ms 内存限制: 65536kB描述输入一个2进制的数,要求输出该2进制数的3进制表示。在3进制的表示中,只有0,1,2三种符号输入第1行是测试数据的组数n,后面跟着n行输入。每组测试数据占1行,包括一个以0和1组成的字符串,字符串长度至少是1,至多是64输出n行,每行输出对应一个输入。样例输入2101101011样例输出211102#include <stdi...原创 2018-03-29 20:51:39 · 5962 阅读 · 0 评论 -
人见人爱A+B
HDOJ上面已经有10来道A+B的题目了,相信这些题目曾经是大家的最爱,希望今天的这个A+B能给大家带来好运,也希望这个题目能唤起大家对ACM曾经的热爱。 这个题目的A和B不是简单的整数,而是两个时间,A和B 都是由3个整数组成,分别表示时分秒,比如,假设A为34 45 56,就表示A所表示的时间是34小时 45分钟 56秒。 Input输入数据有多行组成,首先是一个整数N,表示测试实例的个数,然...原创 2018-03-29 21:21:49 · 683 阅读 · 0 评论 -
decimal system
E - decimal system HDU - 2106 As we know , we always use the decimal system in our common life, even using the computer. If we want to calculate the value that 3 plus 9, we just import 3 and 9.after c...原创 2018-03-30 22:15:57 · 448 阅读 · 0 评论 -
Basically Speaking
The Really Neato Calculator Company, Inc. has recently hired your team to help design their Super Neato Model I calculator. As a computer scientist you suggested to the company that it would be neato ...原创 2018-04-16 08:46:55 · 594 阅读 · 0 评论 -
A+B Coming
Many classmates said to me that A+B is must needs. If you can’t AC this problem, you would invite me for night meal. ^_^ InputInput may contain multiple test cases. Each case contains A and B in one l...原创 2018-04-16 09:35:13 · 512 阅读 · 0 评论 -
又一版 A+B
输入两个不超过整型定义的非负10进制整数A和B(<=2 31-1),输出A+B的m (1 < m <10)进制数。Input输入格式:测试输入包含若干测试用例。每个测试用例占一行,给出m和A,B的值。 当m为0时输入结束。Output输出格式:每个测试用例的输出占一行,输出A+B的m进制数。Sample Input8 1300 482 1 70Sample Output250...原创 2018-04-16 09:56:24 · 476 阅读 · 2 评论 -
Sky数 HDU - 2097
Sky从小喜欢奇特的东西,而且天生对数字特别敏感,一次偶然的机会,他发现了一个有趣的四位数2992,这个数,它的十进制数表示,其四位数字之和为2+9+9+2=22,它的十六进制数BB0,其四位数字之和也为22,同时它的十二进制数表示1894,其四位数字之和也为22,啊哈,真是巧啊。Sky非常喜欢这种四位数,由于他的发现,所以这里我们命名其为Sky数。但是要判断这样的数还是有点麻烦啊,那么现在请你帮...原创 2018-04-05 22:35:54 · 205 阅读 · 4 评论