Easy Tutorial
❮ Python Leap Year Ref Math Inf ❯

Python3 chr() Function

Python3 Built-in Functions


Description

The chr() function takes an integer as a parameter and returns the corresponding character.

Syntax

Here is the syntax for the chr() method:

chr(i)

Parameters

Return Value

The return value is the ASCII character corresponding to the given integer.


Examples

Below are examples demonstrating the use of the chr() method:

>>> chr(0x30)
'0'
>>> chr(97)
'a'
>>> chr(8364)
'€'

Python3 Built-in Functions

❮ Python Leap Year Ref Math Inf ❯