Scope and Accessing Class Members
A class’s data members and member functions belong
to that class’s scope.
Nonmember functions are defined at global namespace
Within a class’s scope, class members are
immediately accessible by all of that class’s member functions and can be
referenced by name.
Outside a class’s scope, class members are
referenced through one of the handles on an object: an object name, a reference
to an object, or a pointer to an object.
Member functions of a class can be overloaded only
by other member functions of that class.
To overload a member function, provide in the class
definition a prototype for each version
of the overloaded function, and provide a separate
definition for each version of the function.
Variables declared in a member function have local
scope and are known only to that function.
The dot member selection operator (.) is preceded
by an object’s name or by a reference to an object to access the object’s
Constructors with Default Arguments
Like other functions, constructors can specify