Preview:
#include <stdio.h>
#include <dos.h>
#include <conio.h>
 
int main()
{
 
   float bal, charge, cred, limit, account, newbal;
   clrscr();
  
   gotoxy(20, 2);
   printf("XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX");
   gotoxy(20, 3);
   printf("X                                       X");
   gotoxy(20, 4);
   printf("X                                       X");
   gotoxy(20, 5);
   printf("X                                       X");
   gotoxy(20, 6);
   printf("X                                       X");
   gotoxy(20, 7);
   printf("X                                       X");
   gotoxy(20, 8);
   printf("X                                       X");
   gotoxy(20, 9);
   printf("X                                       X");
   gotoxy(20, 10);
   printf("X                                       X");
   gotoxy(20, 11);
   printf("X                                       X");
   gotoxy(20, 12);
   printf("X                                       X");
   gotoxy(20, 13);
   printf("X                                       X");
   gotoxy(20, 14);
   printf("X                                       X");
   gotoxy(20, 15);
   printf("X                                       X");
   gotoxy(20, 16);
   printf("X                                       X");
   gotoxy(20, 17);
   printf("X                                       X");
   gotoxy(20, 18);
   printf("X                                       X");
   gotoxy(20, 19);
   printf("X                                       X");
   gotoxy(20, 20);
   printf("X                                       X");
   gotoxy(20, 21);
   printf("X                                       X");
   gotoxy(20, 22);
   printf("X                                       X");
   gotoxy(20, 22);
   printf("XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX");


  
  
  
  gotoxy(26, 5);
   printf("Enter beginning balance:");
   scanf("%f", &bal);
  
   gotoxy(29, 7);
   printf("Enter total charge:");
   scanf("%f", &charge);
  
   gotoxy(28, 9);
   printf("Enter total credits:");
   scanf("%f", &cred);
  
   gotoxy(29, 11);
   printf("Enter credit limit:");
   scanf("%f", &limit);
  
   gotoxy(34, 13);
   printf("Account:");
   scanf("%f", &account);
  
  
   newbal=bal+charge-cred;
 
   gotoxy(30, 15);
   printf("Credit limit: %.2f\n", limit);
  
   gotoxy(34, 17);
   printf("Balance: %.2f\n", newbal);
  
   gotoxy(28, 19);
   (newbal>limit)? printf("Credit Limit Exceeded"): printf("Credit Limit not Exceeded");
  
  

   getch();
   return 0;
}
downloadDownload PNG downloadDownload JPEG downloadDownload SVG

Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!

Click to optimize width for Twitter