interger to ascii string python code example
Example 1: int to ascii python
# converting intefer to ascii number
# declaring variable
i = 3
ord(str(i)) # output --> 51
Example 2: python ascii code to string
>>> L = [104, 101, 108, 108, 111, 44, 32, 119, 111, 114, 108, 100]
>>> ''.join(chr(i) for i in L)
'hello, world'