Exercises

1. Compute and print tax amounts for an individual. Assume you are given the individual's annual income. The taxes are computed based on the following table:
Annual Income Tax Rate
35,000 - 49,999 5%
50,000 - 74,999 10%
75,000 - 99,999 25%
100,000+ 50%

Modify the algorithm to compute and print taxes for any number of individuals.

2. Write an algorithm to compute the balance in a bank account after 5 years. Assume you are given the principal amount, and an annual interest rate. Your algorithm must be constrained to use only the basic arithmetic operations of addition, subtraction, multiplication, and division.
3. Write an algorithm to compute and print the average of an unspecified number of values.




Back to table of contents

Document:
Local Date:
Last Modified On: