Write a Money class holding an amount in whole cents. dollars returns the whole dollars, cents returns the leftover cents, and format returns the amount as text like "$3.25" — always with two digits after the point.
class Money { Money(int totalCents); int dollars(); int cents(); String format(); }
Examples
There are also 4 hidden tests you can't see. Solve the problem, not the examples.