Instantiation of object in dynamic memory
The classMain function uses the new operator to instantiate an object of the Hello2 class in dynamic memory.
The address of the object in dynamic memory is saved in a pointer variable named ptrToObject.