Homework3

# Homework3 - macro that will print the lower of two numbers...

This preview shows page 1. Sign up to view the full content.

Homework 3 You get over paid by a bank to do numeric processing on clients files. Due to an overwhelming number of errors in the books recently, you have been required to write a program to do your job. Luckily the books are in a format that is easy to process and you have broken down the tasks you need the program to accomplish into three main parts. You can even use this formula to predict the ith value in the books in dollars: F(i)=(i*7+1)%20 Part 1 : Since company management is British, you would like to try and appease the powers that be by converting the books to their native currency. Write a program that will convert the first ten numbers (given by F(0) through F(9)) from dollar amounts into British pounds. The conversion rate is currently 1 US dollar = 0.6418 British pounds. Part 2 : Write a macro that will print the larger of two numbers. Also write a
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: macro that will print the lower of two numbers. Obviously if they are equal you return the number. (This will make part 3 easier.) Part 3 : Due to issues with your company’s books in the past, the IRS requires you to keep track of certain statistics. Also, the IRS still wants to see all of the steps leading up to the results in the books. Add a section to your program that will compute some more statistics for the first 10 numbers. At each step print the max (using your macro), min, sum, and average of the numbers entered thus far. As the IRS does not believe in British pounds, these statistics should be computed using dollar amounts, as provided by the formula. You will receive no credit if the book numbers or statistics are hard coded into your program....
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online