#include <stdio.h>
#include <stdlib.h>
int main() {
float
totborc,balance,charg,credit,limit;
int
account,say=0;
printf("Please
enter account number (-1 to end)");
scanf("%d",&account);
while(account!=-1){
printf("Please
enter begining balance ");
scanf("%f",&balance);
printf("Please
enter total charge");
scanf("%f",&charg);
printf("Please
enter credit limit");
scanf("%f",&limit);
printf("Please
enter total credit");
scanf("%f",&credit);
totborc=charg+balance+credit;
if(totborc>limit){
printf("Credit
Limit Exceeded.\n");
}else{
printf("Credit
Limit Not Exceeded.\n");
}
say++;
printf("Please
enter account number (-1 to end)");
scanf("%d",&account);
}
if(say==0){
printf("-1
Yapip Programdan Ciktiniz\nAncak Hic Islem Yapmadan Ciktiniz\n");
}
if(say==1){
printf("-1
Yapip Programdan Ciktiniz\nAncak Sadece 1 Islem Yapip Ciktiniz\nUmariz Yardimci
Olmusuzdur");
}
if(say>1){
printf("-1
Yapip Programdan Ciktiniz\nUmariz Yardimci Olmususdur\n");
printf("%d
tane Hesap kontrolu yaptiniz",say);
}
return
0;
}
Hiç yorum yok:
Yorum Gönder