August 2020
Beginner to intermediate
653 pages
16h 55m
English
It’s time for another project. You’re going to continue building on the fixed type from Project 2 and incorporate what you’ve learned about locales and I/O. Your task this time is to write a currency type. The value is stored as a fixed-point value. I/O is formatted using the get_money and put_money manipulators .
Make sure you can add two currency amounts to get a currency value , subtract two currency amounts to get currency, multiply and divide currency by an integer or rational value to get a currency result, and divide two currency values to get a rational result.
As with any project, ...