Run Code
|
API
|
Code Wall
|
Users
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Blog
Interest Compounding
//g++ 7.4.0 //interest compounding //created by Rezaul Hoque on December 10,2020 //contact at jewelmrh@yahoo.com #include <iostream> #include <cmath> using namespace std; int main () { double s, p,m, i, t,it,base, top, etop; cout<<"Enter principal, interest rate & time:\n"; cin>>p>>i>>t; cout<<"Now enter number of times the principal to be compounded:\n"; cin>>m; base=(1+(i/m)); etop=i*t; top=m*t; //multiple compounding if(m<365) s=p*pow(base,top); else //continuous compounding s=p*exp(etop); cout<<"After "<<t<<" year(s) the $ "<< p<<" will become $ "<< s<<endl;qq return 0; }
run
|
edit
|
history
|
help
0
Please
log in
to post a comment.
delta
3 and 7 in a row
poker.hpp
Barnicle
Bucket Graph Creation
Conjuntos - analizar la lógica
Compare boost optional with the actual value
11080 WIP
tree
-Wall -std=c++14 -O0 -o a.out source_file.cpp
Please log in to post a comment.