Thiago .
/
OOP_Heranca
How to use Inheritance and constructor overloading
Revision 1:6289618eacd1, committed 2015-08-05
- Comitter:
- Jamess
- Date:
- Wed Aug 05 18:16:34 2015 +0000
- Parent:
- 0:4731d40a338a
- Commit message:
- Heran?a;
Changed in this revision
--- a/Brother.cpp Wed Aug 05 17:27:08 2015 +0000 +++ b/Brother.cpp Wed Aug 05 18:16:34 2015 +0000 @@ -3,6 +3,7 @@ Brother::Brother(){ age = 10; + howMuchMoney = 0; }
--- a/Brother.h Wed Aug 05 17:27:08 2015 +0000 +++ b/Brother.h Wed Aug 05 18:16:34 2015 +0000 @@ -15,7 +15,9 @@ Brother(uint32_t myAge); protected: - //TODO + // Who has access + // Inherited classes + uint32_t howMuchMoney; };
--- a/Sister.cpp Wed Aug 05 17:27:08 2015 +0000 +++ b/Sister.cpp Wed Aug 05 18:16:34 2015 +0000 @@ -2,6 +2,6 @@ Sister::Sister(){ - //canot access age; + howMuchMoney = 0; } \ No newline at end of file