Tag c++ constructors rule of 5

C++ Constructors

Constructors A constructor in C++ is a special method that is automatically called when an object of a class is created. To create a constructor, use the same name as the class, followed by parentheses () :