Need Assistance?

support@tutorialshub.in

Object-Oriented Programming (OOP) Core

Constructors in Java

ADVERTISEMENT
Java Free Lesson
5 min read
ADVERTISEMENT

A Constructor has the exact same name as the class, has no return type (not even void), and initializes a new object. If you don't write any constructor, Java provides a default no-arg constructor automatically.

ADVERTISEMENT
Hi, I'm Tuby! Here to help you