View the step-by-step solution to:

Write a C++ program with functions that will calculate the interest on one or more customers' credit card's unpaid balances using the average daily...

Write a C++ program with functions that will calculate the interest on one or more customers' credit card's unpaid

balances using the average daily balance.

Program Input

The standard input for this program which will also be echoed, is:

 Customer's first and last name

 Credit card number

 Balance shown in the bill (netBalance)

 Payment made (payment)

 Days in the billing cycle (d1)

 Number of days payment made before billing cycle (d2)

Calculate the average daily balance, interest, and APR based on the formulas given below:

averageDailyBalance = (netBalance * d1 - paynment * d2)/d1

interest = averageDailyBalance *APR/(100*12)

where APR depends on the average daily balance as shown below

averageDailyBalance <$100 APR = 5%

averageDailyBalance between $100 and $1000 APR = 10%

averageDailyBalance >$1000 APR = 15%

Your program will utilize functions to:

1. Read first and last name (void function)

2. Read credit card number (value returning function)

a. Use a void function to verify read credit card number is correct

3. Read the balance shown in bill (netBalance), payment made (payment), days in billing cycle (d1), and number days

payment made before billing cycle (d2) using a void function

4. Calculate the average daily balance using a void function

5. Determine the APR using a value returning function

6. Determine the interest using a void function

7. Output the results using a void function

Recently Asked Questions

Why Join Course Hero?

Course Hero has all the homework and study help you need to succeed! We’ve got course-specific notes, study guides, and practice tests along with expert tutors.

-

Educational Resources
  • -

    Study Documents

    Find the best study resources around, tagged to your specific courses. Share your own to gain free Course Hero access.

    Browse Documents
  • -

    Question & Answers

    Get one-on-one homework help from our expert tutors—available online 24/7. Ask your own questions or browse existing Q&A threads. Satisfaction guaranteed!

    Ask a Question