Tarantino Mad Dog Sanatorium accepts all breeds and colors of dogs for two-week vacations. Registration is open until November 2, 3126. Fill out one of the following three questionnaires: attentive owners indicate the name, height, and color of the pet; less attentive owners — the name and height; those with their heads in the ground — only the name. Create the Dog class and three constructors for registration.
You must be signed in to leave a comment
25 February 2020, 08:53
why is void not right with constructors ?
4 February 2021, 09:03
A class contains constructors that are invoked to create objects from the class blueprint. Constructor declarations look like method declarations—except that they use the name of the class and have no return type. https://docs.oracle.com/javase/tutorial/java/javaOO/constructors.html
Mrrobot993 Full Stack Developer
18 October 2021, 08:59
Because it's a default behavior, Java recognize constructors from their name