Page

Simple Interest System Code in C/C++

#include<iostream.h>
#include<stdio.h>
#include<conio.h>
#include<dos.h>
void main()
{
float p,r,t,intrest;
int i,j;
clrscr();
gotoxy(10,1);
for(i=1;i<=60;i++)
{
printf("%c",205);
}
gotoxy(10,5);//line
for(i=1;i<=60;i++)
{
printf("%c",205);
}
gotoxy(30,2);
textcolor(RED);
cprintf("SIMPLE INTEREST SYSTEM");
gotoxy(39,3);
cout<<"BY";
gotoxy(35,4);
textcolor(GREEN+BLINK);
cprintf("KR KUMAWAT");
gotoxy(10,6);
cout<<"Enter The Value Of Principal:";
gotoxy(40,6);
cin>>p;
gotoxy(10,7);
cout<<"Enter Time (in Year)        :";
gotoxy(40,7);
cin>>t;
gotoxy(42,7);
cout<<"year";
gotoxy(10,8);
cout<<"Enter Rate (on Principal)  :";
gotoxy(40,8);
cin>>r;
gotoxy(20,10);//line
for(i=1;i<=40;i++)
{
printf("%c",205);
}
gotoxy(20,20);//line
for(i=1;i<=40;i++)
{
printf("%c",205);
}
gotoxy(34,11);
textcolor(WHITE+BLINK);
cprintf("TOTAL INTEREST");
delay(500);
gotoxy(20,13);
cout<<"Principal  :"<<p;
gotoxy(20,14);
cout<<"Rate       :"<<r;
gotoxy(20,15);
cout<<"Time       :"<<t<<"Year";
gotoxy(30,17);

intrest=p*r*t/100;
delay(300);
textcolor(WHITE);
cprintf("INTREST :");
gotoxy(40,17);
cout<<intrest<<"/-";
getch();

}


OUTPUT



No comments:

Post a Comment