Blog_Banner_Asset
    Homebreadcumb forward arrow iconBlogbreadcumb forward arrow iconSoftware Developmentbreadcumb forward arrow iconBuilt in Functions in Python: Explained with Examples

Built in Functions in Python: Explained with Examples

Last updated:
10th Feb, 2023
Views
Read Time
5 Mins
share image icon
In this article
Chevron in toc
View All
Built in Functions in Python: Explained with Examples

Built in Functions in Python

In Python, a function is a block of statements related to each other and performs a particular operation or task. There are three types of functions in Python. They are Built-in or library functions, User-defined functions and Anonymous functions. The functions defined by the programmer or the user to perform a specific task is called the user-defined function in Python. Anonymous functions are those functions in a Python code without mentioning a name. 

Check out our free courses to get an edge over the competition.

Explore our Popular Software Engineering Courses

All about Built-in Functions

Built in functions in Python are those functions that are predefined in Python to perform default tasks. These are the functions available within the Python interpreter for use at any instant it is invoked. There are 69 built in functions in Python.

Ads of upGrad blog

Learn Software Development Courses online from the World’s top Universities. Earn Executive PG Programs, Advanced Certificate Programs or Masters Programs to fast-track your career.

In-Demand Software Development Skills

Built in functions and their predefined tasks

Built-in functionTask Performed
abs()Absolute value of a number is returned.
all()A true value is returned when all elements in the iterable are true.
any()This function is responsible for checking if any of the iterable elements is true.
ascii()A string with printable illustration is returned.
bin()It converts an integer to a binary number.
bool()This function is invoked to convert a value to Boolean.
breakpoint()It is called to drop the user into the debugger.
bytearray()An array given byte size is returned when this function is called. 
bytes()This function returns an array of bytes with an integer sequence that cannot be changed.
callable()The function is invoked to check if an Object can be called or not.
chr()A string is returned from an integer.
classmethod()The class method of a given function is returned.
compile()Returns the Object of a Python code.
complex()This function is invoked to generate a complex number.
delattr()The attributes of the Object are deleted when this function is called.
dict()A dictionary can be with this function.
dir()With this function, an attempt is made to return the Object’s attributes.
divmod()Used to return a tuple of quotients and remainder in integer division.
enumerate()An Enumerate Object is returned.
eval()This function executes a Python code within the written program.
exec()We use this function to facilitate the dynamic execution of Python code. 
filter()An iterator is developed for those elements for which the function returns a true value.
float()With this function, a number or a string can return a floating-point value.
format()The returned value is converted to a formatted representation.
frozenset()The function returns a new frozenset Object that cannot be altered.
getattr()The function is invoked to return the value of an Object’s named attribute.
globals()The current global symbol table’s dictionary is returned.
hasattr()It tells whether the Object or string has a named attribute or not.
hash()This function is invoked to obtain the hash value of an Object. 
help()An in-built help system is invoked for interaction.
hex()To accomplish the integer to hexadecimal conversion.
id()Identity of an Object is returned.
input()A string line is read and returned.
int()An integer value is returned from a number or a string.
isinstance()To examine whether an Object is the class’s instance.
issubclass()To check whether the invoked class is a subclass of another class or not.
iter()An iterator is returned when this function is called. 
len()To return the length of an Object.
list()This function generates a list in Python code.
locals()The current local symbol table’s dictionary is returned.
map()An iterator that applies the function to return the list with the invoke of this function.
max()The item with maximum value in the iterable is returned.
memoryview()The given argument’s ‘memory view’ Object is returned.
min()The function returns an item with the minimum value in the iterable.
next()The function is used to retrieve the iterator’s next item.
object()The function returns a new featureless Object.
oct()An octal representation of the given integer is returned.
open()The function opens a file and returns the file Object.
ord()The Unicode character’s integer value is returned.
pow()The exponent of a number is returned.
print()Used to print the given Object.
property()The function is used to return property attribute
range()Invoked to return a sequence of integers from start to stop.
repr()Returns a string with the Object’s printable representation.
reversed()This function is used to obtain the reverse of an iterator sequence.
round()A number is rounded to specified decimal.
set()The function formulates and returns a set.
setattr()It sets a value to the Object’s attribute.
slice()A slice Object is returned with this function.
sorted()The sorted list of given iterable is extracted with this function.
staticmethod()A method is transformed into a static method.
str()An Object’s string version is returned.
sum()Elements of the iterable are added.
super()The base class’s proxy Object is returned.
tuple()The function returns a tuple.
type()The type of an Object is returned.
vars()The function returns the _dict_ attribute of an Object.
zip()An aggregate is made from elements of each iterable.
_import__()The ‘import’ statement invokes this function.

At upGrad, our Executive Post Graduate Programme in Software Development – Specialisation Cloud Backend Development, offered in collaboration with IIITB, is a 12-15 months program aimed at both freshers and experienced professionals wanting to understand cloud computing in more detail. The course is highly training-oriented and gives you all the practical exposure you require to get started in the world of software development and cloud computing. Check out the course page and get yourself enrolled soon!

Ads of upGrad blog
Profile

Pavan Vadapalli

Blog Author
Director of Engineering @ upGrad. Motivated to leverage technology to solve problems. Seasoned leader for startups and fast moving orgs. Working on solving problems of scale and long term technology strategy.

Explore Free Courses

Suggested Tutorials

View All

Suggested Blogs

Top 14 Technical Courses to Get a Job in IT Field in India [2024]
90952
In this Article, you will learn about top 14 technical courses to get a job in IT. Software Development Data Science Machine Learning Blockchain Mana
Read More

by upGrad

15 Jul 2024

25 Best Django Project Ideas & Topics For Beginners [2024]
143863
What is a Django Project? Django projects with source code are a collection of configurations and files that help with the development of website app
Read More

by Kechit Goyal

11 Jul 2024

Must Read 50 OOPs Interview Questions & Answers For Freshers & Experienced [2024]
124781
Attending a programming interview and wondering what are all the OOP interview questions and discussions you will go through? Before attending an inte
Read More

by Rohan Vats

04 Jul 2024

Understanding Exception Hierarchy in Java Explained
16878
The term ‘Exception’ is short for “exceptional event.” In Java, an Exception is essentially an event that occurs during the ex
Read More

by Pavan Vadapalli

04 Jul 2024

33 Best Computer Science Project Ideas & Topics For Beginners [Latest 2024]
198249
Summary: In this article, you will learn 33 Interesting Computer Science Project Ideas & Topics For Beginners (2024). Best Computer Science Proje
Read More

by Pavan Vadapalli

03 Jul 2024

Loose Coupling vs Tight Coupling in Java: Difference Between Loose Coupling & Tight Coupling
65177
In this article, I aim to provide a profound understanding of coupling in Java, shedding light on its various types through real-world examples, inclu
Read More

by Rohan Vats

02 Jul 2024

Top 58 Coding Interview Questions & Answers 2024 [For Freshers & Experienced]
44555
In coding interviews, a solid understanding of fundamental data structures like arrays, binary trees, hash tables, and linked lists is crucial. Combin
Read More

by Sriram

26 Jun 2024

Top 10 Features & Characteristics of Cloud Computing in 2024
16289
Cloud computing has become very popular these days. Businesses are expanding worldwide as they heavily rely on data. Cloud computing is the only solut
Read More

by Pavan Vadapalli

24 Jun 2024

Top 10 Interesting Engineering Projects Ideas & Topics in 2024
43094
Greetings, fellow engineers! As someone deeply immersed in the world of innovation and problem-solving, I’m excited to share some captivating en
Read More

by Rohit Sharma

13 Jun 2024

Schedule 1:1 free counsellingTalk to Career Expert
icon
footer sticky close icon