Let’s explore these methods gradually — from simple initialization, to “dunderifying” your class into something that acts like a list, a number, or even a callable function. __init__ is invoked. It's ...
In my last post, I talked about Object-Oriented Programming(OOP). And I specifically talked about a single magic method __init__ which is also called as a constructor method in the OOP terminology.