24 Oct Aurora Wednesday 18:30 Python Practice 21.10.20.
Question:
Modify the program we made in the class, so you could convert decimal number into any base number between Binary(base 2 number ) to Hex(base 16 number)
remember the hex number (base 16 number) is consist of 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F
while OCT number (base 8 number) is consist of 0,1,2,3,4,5,6,7 only
you could use windows calculator with option of “programmer” to check your answer.
Sample Input 1: Number: 1258 Base: 16 Sample Output 1: 4EA
Sample Input 2: Number: 1258 Base: 8 Sample Output 2: 2352
Sorry, the comment form is closed at this time.