Python Constructor-TCCI-tccicomputercoachig.com

Page 1

Python Constructor-TCCItccicomputercoachig.com Python Constructors A constructor is a special type of method (function) which is used to initialize the instance members of the class.

2 Types of Constructor 1.parameterized 2. non-parameterized Constructor definition executes when we create object of the class. Constructors also verify that there are enough resources for the object to perform any start-up task. Destructor Destructors are called when an object gets destroyed. It’s the polar opposite of the constructor, which gets called on creation. These methods are only called on creation and destruction of the object. They are not called manually but completely automatic. To know more about python at TCCI. Call us @ 9825618292 Visit us @ http://tccicomputercoaching.com/


Turn static files into dynamic content formats.

Create a flipbook
Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.
Python Constructor-TCCI-tccicomputercoachig.com by Rosario Riley - Issuu