0

Is use of constructor in any program good or bad, if bad. What is another solution for construction based problems?

6th Oct 2019, 3:22 PM
Pushpendra Singh
Pushpendra Singh - avatar
2 Réponses
0
You don't 'have' to include you own constructors. They are normally used to initialise an objects' variables. In c++ if you don't 'supply' a constructor, the compiler will add a default constructor for you. Not sure what happens in python though.
6th Oct 2019, 5:12 PM
rodwynnejones
rodwynnejones - avatar