Keywords are reserved words of programming languages. Every word in a python program is classified as either a keyword or an identifier or an operator.
- The keywords can not be an identifier.
- The meaning of the reserved words or keywords has already been explained to the Interpreter or compiler.
All python keywords are listed below :-
The above keywords may vary in different versions of Python. Some extra might get added to the language or some might be removed.
We can get the list of keywords in your current version by typing the following in python shell.
Using Intermediate mode :-
Using Script mode :-
This will print all the keywords of the current version of python in your system. The output of the above code :-
Note : We have discuss each keyword in detail. Checkout the tutorials here.