2012-09-04T09:58:31-04:00
Write a program to compute simple interest and compound interest
1
2012-09-06T10:05:12-0400
#include<stdio.h> #include<math.h> #include<conio.h> int main() { float p,rate,time,ci; printf("Enter principal amount : "); scanf("%f", &p); printf("Enter interest rate : "); scanf("%f", &rate); printf("Enter time period in year : "); scanf("%f", &time); //calculate ci ci=p*(pow((1+rate/100),time)-1); printf(" Compound interest = %f",ci); return 0; } Output :- Enter principal amount : 48500 Enter interest rate : 6 Enter time period in year : 2 Compound interest = 5994.600098
Need a fast expert's response?
Submit order
and get a quick answer at the best price
for any assignment or question with DETAILED EXPLANATIONS !
Learn more about our help with Assignments:
C++
Comments