How to make a constructor in java


#1

https://www.codecademy.com/courses/learn-java/lessons/object-oriented-programming/exercises/classes-constructors?action=lesson_resume

In this link (Classes: Constructors) i cant figure it out how to make a constructor in java.
Plz anybody help…


#2

but there is an example with constructor in the information section:

class Car {

    //The class constructor for the Car class
    public Car() {

    }
}

there is even a comment, telling what the constructor is.


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.