hi
can any one guide what iam doing wrong in this program as dev c++ compiler giving error which i cant understand here is the print screen of the same and the code
can any one guide what iam doing wrong in this program as dev c++ compiler giving error which i cant understand here is the print screen of the same and the code
Rich (BB code):
/*
Name: mkbutan
Copyright:
Author:
Date: 02/08/12 20:38
Description: pg8 1.5
*/
#include<stdio.h>
#include<conio.h>
#define PERIOD 10
#define PRINCIPAL 5000.00
main()
{
int year;
float amtount,value,inrate;
amount = PRINCIPAL;
inrate = 0.11;
year = 0;
while(year<=PERIOD)
{
printf("%2d %8.2f\n",year,amount);
value = amount + inrate * amount;
year = year + 1;
amount = value;
}
getch();
}
Attachments
-
152.3 KB Views: 19