Question #21457

You are to write a program that calculates the ascii numbers when given any decimal number between 0 and 255. The program is to contain a function call deciToAscii(number) that accepts the decimal argument and returns an ascii number as an eight character string.

Expert's answer

def deciToAscii(number):
return ''.join([str(ord(x)) for x in str(number)])

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

LATEST TUTORIALS
APPROVED BY CLIENTS