I need documentation for class object functions. 4 using namespace std;class Money{7 private:8.int dollars;int cents;1011public:int getDollars();int getCents ( ) ;12131415Money(int...


I need documentation for class object functions.


Q A<br>h Money<br>Hierarchical<br>Flat<br>h Money ) No Selection<br>1<br>#ifndef MONEY_H<br>2<br>#define MONEY_H<br>#include<iostream><br>4 using namespace std;<br>class Money<br>{<br>7 private:<br>8.<br>int dollars;<br>int cents;<br>10<br>11<br>public:<br>int getDollars();<br>int getCents ( ) ;<br>12<br>13<br>14<br>15<br>Money(int dollars, int cents);<br>16<br>Money ();<br>Money operator+(Money);<br>17<br>18<br>19<br>20<br>Money operator-(Money);<br>21<br>22<br>Money operator*(double p1);<br>23<br>24<br>Money operator/(double p1);<br>25<br>26<br>bool operator==(Money p1);<br>27<br>28<br>Money operator%(Money p1);<br>29<br>30<br>friend ostream &operator<<(ostream &output, Money);<br>31<br>32<br>friend istream &operator>>(istream &output, Money&);<br>33 };<br>Money operator*(double num, Money obj);<br>Money operator%(int num, Money obj<br>34<br>35<br>36<br>37<br>#endif<br>38<br>O Filter<br>M<br>Line: 35 Col: 44<br>

Extracted text: Q A h Money Hierarchical Flat h Money ) No Selection 1 #ifndef MONEY_H 2 #define MONEY_H #include 4 using namespace std; class Money { 7 private: 8. int dollars; int cents; 10 11 public: int getDollars(); int getCents ( ) ; 12 13 14 15 Money(int dollars, int cents); 16 Money (); Money operator+(Money); 17 18 19 20 Money operator-(Money); 21 22 Money operator*(double p1); 23 24 Money operator/(double p1); 25 26 bool operator==(Money p1); 27 28 Money operator%(Money p1); 29 30 friend ostream &operator<(ostream &output,="" money);="" 31="" 32="" friend="" istream="" &operator="">>(istream &output, Money&); 33 }; Money operator*(double num, Money obj); Money operator%(int num, Money obj 34 35 36 37 #endif 38 O Filter M Line: 35 Col: 44

Jun 11, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here