Python double under (dunder) methods
Dunder stands for "double + under" methods
__init__ __str__ __call__ __setitem__ __getitem__ __delitem__ __len__ __add__ __contains__ __repr__
Related
- Methods
- Classes
- Double underscore
- Class methods
- Python, C
- Polymorphism
_xxxx
and__xxxx
. Read https://docs.python.org/3/tutorial/classes.html#private-variablesfrom os import open as open_
- Underscore
- if __name__ == "__main__":
Activities
- http://python-history.blogspot.com/2009/02/adding-support-for-user-defined-classes.html
- What is the difference between __str__ and __repr__?
See also
- Python, PIP, GIL, Flask, Django, Marshmallow,
def
, logging, Pandas, Numpy, AWS Chalice,import
,from
,tuple
,list
, Python exceptions,virtualenv
,.append
,pytz
,TZ
,print
,python3 -c
,os
, PEP, Python Institute, Methods: Dunder methods, Flake8, Python collections, Function decorators in Python, Click python library, Python module, Flower,kwargs
, Black (Python), Python list structure, Mypy,variables
, Casting,try:
, pydoc, argparse, Anaconda,pyenv, setup.py, python3 --version, python3 --help
, Data Classes, raise
Advertising: