python十分简单实现十进制到任意进制的转换
摘要:
1 def ten_to_sixteen(n,x): 2 a=[0,1,2,3,4,5,6,7,8,9,'A','B','C','D','E','F'] 3 b=[] 4 while True: 5 s = n //x 6 y = n % x 7 b = b+[y] 8 if s == 0: 9 b 阅读全文
posted @ 2019-06-05 17:57 vmaze 阅读(711) 评论(0) 推荐(0) 编辑