ScanSkill

chr

This chr() function returns a string of one character whose ASCII code is the specified number.

Syntax

chr(number)

Here,

  • number: Required. Integer within the 0-255 range.

Examples

>>> chr(65)
'A'
>>> chr(97)
'a'
>>> ''.join([chr(c) for c in range(65, 91)])
'ABCDEFGHIJKLMNOPQRSTUVWXYZ'

Here, .join() is used to concatenate all the strings.