How to view a list of all Python operators via the interpreter?


The help method in the interpreter is very useful for such operations. It provides a rich set of special inputs that you can give to it to get information about the different aspects of the language. Forgetting operator lists, here are some of the commands you can use:

All operators

>>> help('SPECIALMETHODS')

Basic operators

>>> help('BASICMETHODS')

Numeric operators

>>> help('NUMBERMETHODS')

Other than operators you can also get attribute methods, callable methods, etc using −

>>> help('MAPPINGMETHODS')
>>> help('ATTRIBUTEMETHODS')
>>> help('SEQUENCEMETHODS1')
>>> help('SEQUENCEMETHODS2')
>>> help('CALLABLEMETHODS')

Lakshmi Srinivas
Lakshmi Srinivas

Programmer / Analyst / Technician

Updated on: 05-Mar-2020

197 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements