The member function of a class which is used for creating objects of that particular class is known as a constructor. It has the same name of a class without any return type. New operator is used to invoke it.
An ordinary member function of a class is known as a method. It has a return type with its own name. Dot operator is used to invoke it.