Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Assuming there are no deposits other than the original investment, the balance i

ID: 3665111 • Letter: A

Question

Assuming there are no deposits other than the original investment, the balance in a savings account after one year may be calculated as:

Amount = Principal * (1 + Rate/T) ^T

where Principal is the balance in the account, Rate is the annual interest rate, and T is the number of times the interest is compounded during a year. (e.g., T is 4 if the interest is compounded quarterly.)

Write a program that asks for the principal, the interest rate, and the number of times the interest is compounded. It should display a report similar to the following:

Interest Rate: 4.25%

Times Compounded: 12

Principal: $ 1000.00

Interest: $ 43.33

Final balance: $ 1043.33

Explanation / Answer

#include<iostream>
#include<cmath>
using namespace std;

int main()
{
double principal,rate,time,amount;
cout<<"enter principal value"<<endl;
cin>>principal;
cout<<"enter interest rate"<<endl;
cin>>rate;
cout<<"enter the time value"<<endl;
cin>>time;
amount=principal*pow((1+rate/time),time);
//cout<<amount;
cout<<"Interest rate: "<<rate<<" %"<<endl;
cout<<"Times compounded: "<<time<<endl;
cout<<"Principal: $"<<principal<<endl;
cout<<"Interest: $"<<amount-principal<<endl;
cout<<"Final balance: $"<<amount<<endl;
return 0;
}

Please don't forget to give me feedback

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote