chr() : Getting Char using Unicode point value as input
Input : takes Unicode point value as input .
returns the equivalent char
Here are some sample outputs of Unicode point value as input ( output is shown against each row after comment )
The first 128 unicode point values are same as ASCII values.
print(chr(97)) # a
print(chr(98)) # b
print(chr(80)) # P
print(chr(35)) # #
print(chr(36)) # $
We can use inputs from 0 to 1114111.
Here is for loop to print some chars with their Unicode point values (Unicode value as inputs). Change the range values to get different set of chars and values.
All Built in Functions in Python
for i in range(200,250):
ord() returns the Unicode point value by taking the Char as input
This article is written by plus2net.com team.