8-CB-1- Title: 36 hex

Title: 36 hexadecimal

For hexadecimal, we use the letters AF to represent the numbers 10 and above.
Next door, and has been used in the letter Z, it can represent 36 decimal.

36-ary, A represents 10, Z represents 35, AA represents 370

Can you calculate the numbers MANY expressed in decimal form is?

Please submit an integer, do not fill in any extra content (for example, caption)

a = (ord('M')-ord('A')+10)*pow(36,3)
b = (ord('A')-ord('A')+10)*pow(36,2)
c = (ord('N')-ord('A')+10)*pow(36,1)
d = (ord('Y')-ord('A')+10)*pow(36,0)
res = a+b+c+d
print("%d"%res)

answer:

1040254

Published 10 original articles · won praise 0 · Views 195

Guess you like

Origin blog.csdn.net/tianrandai12/article/details/104089582
36