Overview image

The Python interpreter comes with some built-in functions that provide useful functionality. Some of the commonly used built-in functions include print(), input()len(), etc.

These functions are a part of the Python language and do not need to be imported or installed.

As of Python 3.11.3 , the total built-in functions sums up to 68. These functions are as shown in the table below:

you can click on a function above to see its syntax, usage and other features.

Where are the functions defined?

The built-in functions in Python are implemented in Python and  partly in C. C is a lower-level language than Python, this allows Python to benefit from the speed and efficiency of C for performance-critical operations.

The builtins module in the standard library provides an interface to access the built-in functions. When you use a built-in function in your Python code, you are actually calling the corresponding function object from the builtins module.

ExampleEdit & Run
import builtins

builtins.print('Hello, World')
builtins.print(builtins.sorted([9,8,7,6,5,4,3,2,1]))
copy
Output:
Hello, World [1, 2, 3, 4, 5, 6, 7, 8, 9] [Finished in 0.010538362432271242s]

You can use the builtin help() function to see more an each function such as usage and arguments.

Syntax:
help(function_name)
copy
ExampleEdit & Run
help('print')
copy
Output:
Help on built-in function print in module builtins: print(*args, sep=' ', end='\n', file=None, flush=False)     Prints the values to a stream, or to sys.stdout by default.          sep       string inserted between values, default a space.     end       string appended after the last value, default a newline.     file       a file-like object (stream); defaults to the current sys.stdout.     flush       whether to forcibly flush the stream. [Finished in 0.05024394812062383s]