The ____ method is used to initialize the object’s attributes in a class.

  • construct
  • create
  • init
  • new
In Python, the __init__ method is a special method (also known as a constructor) used to initialize the attributes of an object when an instance of a class is created. It allows you to set the initial state of the object.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *