Classes and Objects - BU Computer Science

Example: int A::getValue() const { return privateDataMember }; Returns the value of a data member but doesn't modify anything so is declared const Constructors / Destructors cannot be const They need to initialize variables, therefore modifying them const (Constant) Objects...

Author:
Uploaded by: Murkka Svensdottir
Filesize: 475 KB