Java / Constructor
What is a Constructor?
A constructor is a construct similar to java method without any return type.
A constructor gets invoked when a new object is created. Every class has a constructor.
In case the developer does not provide a constructor for a class, the Java compiler (Javac) creates a default constructor for that class.
More Related questions...