A constructor is a special function used to create and initialize objects.
It helps you create multiple objects with the same properties and methods.
In JavaScript, constructors are mainly used with:
• The new keyword
• Constructor Functions
• Classes (ES6)