Answered step by step
Verified Expert Solution
Question
1 Approved Answer
The image explains it all Lab 5 - Compound Interest For this assignment, you must also write pseudocode, in addition to your C program, and
The image explains it all Lab 5 - Compound Interest
For this assignment, you must also write pseudocode, in addition to your C program, and show correct operation for the following programs:1) The first program will compute compounded interest. Suppose you invest $1000.00 at an interest rate of 2% per year. If the interest is computed at the end of each day, it is added to your account (i.e., the interest is compounded daily). Print what the account value will be at the end of each year for 20 years. Use data type double for money. For 365 days per year (ignore leap year), the daily interest rate is 2%/ 365. Your program should request the following numbers as input from the user with scanf():Initial account balance (Start with $1000.00)
Then run and demonstrate it again with the last 6 digits of your Red ID# so 876123456 would be: 1234.56)The annual interest rate in percentNumber of years: run it for at least 10 yearsFor a compounding period of 1 (daily), the interest must be computed 365 times and accumulated. For a compounding period of 30 (monthly), the interest would be computed 365/30 or 12 times.Print the amount in the account including accumulated interest for each of 20 years for the following compounding periods if you started with $1,000 dollars:
Daily (period 1)Weekly (7)Monthly (30)Quarterly (90)Annually (365)Use DOUBLE variables for your calculations. Run your program again for daily compounding using FLOAT variables, and note the difference in the results. Output should be formatted in columns, by year number something like this:Year Daily Weekly Monthly Quarterly Annually---- ------- ------- ------- --------- ------- 0 1000.00 1000.00 1000.00 1000.00 1000.00 1 100x.xx 100x.xx 100x.xx 100x.xx 100x.xx 2 10xx.xx ...
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started