1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101
|
#include<stdio.h>
#include<conio.h>
#include<stdlib.h>
main(void)
{
clrscr();
int croissant,tamis,tamiswcheese,falafil,cocktail,pepsi,water;
int c,t,tc,f,cock,p,w;
int c1,t1,tc1,f1,cock1,p1,w1;
int total;
croissant=2;
tamis=5;
tamiswcheese=7;
falafil=5;
cocktail=5;
pepsi=2;
water=1;
textcolor(YELLOW);
gotoxy(19,4);
cprintf("We offer you: Price How many Cost ");
textcolor(YELLOW);
gotoxy(19,7);
cprintf("1. Croissant 2 SR ");
cscanf("%d",&c);
gotoxy(69,7);
c1=croissant*c;
cprintf("%d SR",c1);
getch();
textcolor(YELLOW);
gotoxy(19,9);
cprintf("2. Tamis 5 SR ");
cscanf("%d",&t);
gotoxy(69,9);
t1=tamis*t;
cprintf("%d SR",t1);
getch();
textcolor(YELLOW);
gotoxy(19,11);
cprintf("3. Tamis w/ Cheese 7 SR ");
cscanf("%d",&tc);
gotoxy(69,11);
tc1=tamiswcheese*tc;
cprintf("%d SR",tc1);
getch();
textcolor(YELLOW);
gotoxy(19,13);
cprintf("4. Falafil 5 SR ");
cscanf("%d",&f);
gotoxy(69,13);
f1=falafil*f;
cprintf("%d SR",f1);
getch();
textcolor(YELLOW);
gotoxy(19,15);
cprintf("5. Cocktail 5 SR ");
cscanf("%d",&c);
gotoxy(69,15);
c1=cocktail*c;
cprintf("%d SR",c1);
getch();
textcolor(YELLOW);
gotoxy(19,17);
cprintf("6. Softdrinks (Any) 2 SR ");
cscanf("%d",&p);
gotoxy(69,17);
p1=pepsi*p;
cprintf("%d SR",p1);
getch();
textcolor(YELLOW);
gotoxy(19,19);
cprintf("7. Water 1 SR ");
cscanf("%d",&w);
gotoxy(69,19);
w1=water*w;
cprintf("%d SR",w1);
getch();
total=c1+t1+tc1+f1+cock1+p1+w1;
textcolor(YELLOW);
gotoxy(60,21);
cprintf("Total: %d SR", total);
getch();
}
|