Google News
logo
Java Constructor - Interview Questions
When do we need Constructor Overloading?
* Sometimes there is a need of initializing an object in different ways. This can be done using constructor overloading. Different constructors can do different work by implementing different line of codes and are called based on the type and no of parameters passed.

* According to the situation , a constructor is called with specific number of parameters among overloaded constructors.
Advertisement