CSCI 1321 (Principles of Algorithm Design II), Spring 2001:
Homework 11

Assigned:
January 22, 2001.

Due:
January 29, 2001, at 5pm.

Credit:
20 points.


Contents

Overview

Write a program to compute the correct state sales tax, given a list of item prices. For example, a retailer selling two items each costing $3.45 and one item costing $123.45 could compute the sales tax by typing

salesTax salesTaxRates TX 3.45 3.45 123.45
into any shell. Here, The program should print 8.15, which is the sales tax due. That is,
(3.45 + 3.45 + 123.45) * 6.25% = 8.146875,
which is then rounded to the closest penny.

Details

What to turn in

Submit your source code as described in the Guidelines for Programming Assignments. Use a subject heading of ``cs1321 hw1'', and submit a single file containing your C++ source code.



Footnotes

... 11
© 2001 Jeffrey D. Oldham and Berna L. Massingill. All rights reserved. This document may not be redistributed in any form without the express permission of at least one of the authors.


Berna Massingill
2001-02-08