hey mates......❤
annyeong☺❤☺❤☺
what is the difference between parameterized Constructor and Default constructor ( points must be varied) *_*
Answers
Default constructor:
================
A constructor which takes no arguments is known as default constructor.
__________
●Compiler inserts a default no-arg constructor after compilation, if there is no explicit constructor defined in class and its datamember is initialise with 0.
●No need to pass any parameters while constructing new objects using default constructor.
●Default constructor is used for initializing objects with same data.
Parametrized constructor:
====================
●A constructor which takes one or more arguments is known as parameterized constructor.
●When parametrized constructor is defined in class, then programmer needs to define default no-arg constructor explicitly if required.
●At least one or more parameters needs to be passed while constructing new objects using argument constructors.
●Whereas parametrized constructor is used to create distinct objects with different data.
================☆☆☆☆☆☆☆☆☆☆☆====================