I have to design a class that represents units of money. There have to be 8 methods or functions within the class. Methods and arguments should be const when it is possible, and the class data should be private. I am supposed to use either 2 integers or a single float to represent units of money. He supplied a header file and it contains this:

cout << "Enter two money amounts as doubles: ";

cin >> m1 >> m2;

cout << "Money object m1 is " << m1 << endl;

cout << "Money object m2 is " << m2 << endl << endl;

if (m1 == m2)

cout << m1 << " equals " << m2 << endl;

if (m1 != m2)

cout << m1 << " does not equal " << m2 << endl;

if (m1 < m2)

cout << m1 << " is less than " << m2 << endl;

if (m1 > m2)

cout << m1 << " is greater than " << m2 << endl;

cout << endl;

cout << "The sum of " << m1 << " and " << m2 << " is " << m1+m2 << endl;

money m3 = 5.95 + m2;

cout << "Adding $5.95 to " << m2 << " yields " << m3 << endl;

These are the 8 functions I believe I need to include, but I am not sure.

If anyone knows anything about this, or can help me at all, I'd really appreciate it. Thanks.