Home >>Python Keywords

Python Keywords

Python Keywords

The reserved words in Python is known as Python Keywords.We can't use Python keywords as a variable name, function name or any other identifier.

Keyword Description
and It defines a logical operator.
as It is used to create an alias.
assert It is used for debugging.
break It is used to break out of the loop.
class It is used to define a class.
continue It is used to continue to the next iteration of a loop.
def It is used to define a function.
del It is used to delete an object.
elif It is used in conditional statements.
else It is used in conditional statements.
except It is used with exceptions.
False It defines a Boolean value.
finally It is used with exceptions.
for It is used to create a for loop.
from It is used to import specific parts of a module.
global It is used to declare a global variable.
if It is used to make a conditional statement.
import It is used to import a module.
in It is used to check if a value is present in a list, tuple, etc.
is It is used to test if two variables are equal.
lambda It is used to create an anonymous function.
None It represents a null value.
nonlocal It is used to declare a non-local variable.
not It defines a logical operator.
or It defines a logical operator.
pass It defines a null statement that will do nothing.
raise It is used to raise an exception.
return It is used to exit a function and return a value.
True It defines a Boolean value.
try It is used to make a try.
while It is used to create a while loop.

Python Keywords Index

Sr.No. Topics
1 Python and Keyword
2 Python as Keyword
3 Python assert Keyword
4 Python break Keyword
5 Python class Keyword
6 Python continue Keyword
7 Python def Keyword
8 Python del Keyword
9 Python elif Keyword
10 Python else Keyword
11 Python except Keyword
12 Python False Keyword
13 Python finally Keyword
14 Python for Keyword
15 Python from Keyword
16 Python global Keyword
17 Python if Keyword
18 Python import Keyword
19 Python in Keyword
20 Python is Keyword
21 Python lambda Keyword
22 Python None Keyword
23 Python nonlocal Keyword
24 Python not Keyword
25 Python or Keyword
26 Python pass Statement
27 Python raise Keyword
28 Python return Keyword
29 Python True Keyword
30 Python try Keyword
31 Python while Keyword

No Sidebar ads