New course! Every coder should learn Generative AI!
Try a free lesson0
What is constructor?
1 Answer
+ 2
A constructor in Java is a special method that is used to initialize objects. The constructor is called when an object of a class is created.it should be name as a class name.