题目:给了两个数,分别可以转成2-36的任意进制,输出相等时的进制。如果都不可以,输出都不行
注意:1 刚开始把两个数存到了两个char数组。刚开始我设置两个数组长度都是10。多次RA后才发现一些很长的就读不进去了。这让我想到看很多大佬的代码。把数组长度define成M,来控制,也可能是为了避免这种问题
2. 题干中有一句话很考验英语“ The bases associatedwith X and Y will be between 1 and 36 (inclusive), and as noted above, need not be the same for X andY . In representing these numbers the digits 0 through 9 have their usual decimal interpretations. ” 注意那个inclusive是放在36后面的。不对!根本就没有1进制。唉。智商呀。所以如果输入两个0,应该是 0 (base 2) = 0 (base 2) ,而不是 0 (base 1) = 0 (base 1)