c++ project restaurant

47
SOURCE CODE #include<iostream.h> #include<process.h> #include<ctype.h> #include<conio.h> #include<graphics.h> #include<stdio.h> void main() { clrscr(); float qty, amt1, amt2, amt3, amt4,amt5, amt6, gt; char ch; int codeno, i=0; gotoxy(2, 1); cout<<"Veg"; gotoxy(4, 2); cout<<"And"; gotoxy(7, 3); cout<<"Non-Veg"; gotoxy(20, 1); cout<<"$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$"; gotoxy(25, 2); cout<<"INDIAN RESTAURANT"; gotoxy(20, 3); cout<<"$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$"; gotoxy(60, 1); cout<<"Get 10% discount"; gotoxy(60, 2); cout<<"on purchasing more"; gotoxy(60, 3); cout<<"than 16 $ ";

Upload: anirudh-gupta

Post on 20-Feb-2016

228 views

Category:

Documents


1 download

DESCRIPTION

cccc

TRANSCRIPT

Page 1: C++ Project Restaurant

SOURCE CODE

#include<iostream.h>#include<process.h>#include<ctype.h>#include<conio.h>#include<graphics.h>#include<stdio.h>void main(){clrscr();float qty, amt1, amt2, amt3, amt4,amt5, amt6, gt;char ch;int codeno, i=0;gotoxy(2, 1);cout<<"Veg";gotoxy(4, 2);cout<<"And";gotoxy(7, 3);cout<<"Non-Veg";gotoxy(20, 1);cout<<"$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$";gotoxy(25, 2);cout<<"INDIAN RESTAURANT";gotoxy(20, 3);cout<<"$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$";gotoxy(60, 1);cout<<"Get 10% discount";gotoxy(60, 2);cout<<"on purchasing more";gotoxy(60, 3);cout<<"than 16 $ ";

gotoxy(1, 4);

cout<<"-------------------------------------------------------------------------------";

gotoxy(1, 5);cout<<"Code ";cout<<"\tContent ";

Page 2: C++ Project Restaurant

cout<<"\t Price($) ";cout<<"\tCode ";cout<<"\tContent ";cout<<"\t Price($) ";gotoxy(1, 6);

cout<<"-------------------------------------------------------------------------------";

gotoxy(10, 7);cout<<"Main Course ";

cout<<"\n 1 ";cout<<"\tDal Makhani ";cout<<"\t 1.50 $ ";

cout<<"\n 2 ";cout<<"\tRajma ";cout<<"\t\t 1.30 $";

cout<<"\n 3 ";cout<<"\tShahi Paneer ";cout<<"\t 2.10 $ ";

cout<<"\n 4 ";cout<<"\tSarson Ka Sag ";cout<<"\t 2.10 $ ";

gotoxy(10, 12);cout<<"Tandoor Se ";

cout<<"\n 5 ";cout<<"\tPlain Roti ";cout<<"\t 0.06 $ ";

cout<<"\n 6 ";cout<<"\tButter Roti ";cout<<"\t 0.11 $";

cout<<"\n 7 ";cout<<"\tAloo Parantha ";cout<<"\t 0.41 $ ";

cout<<"\n 8 ";

Page 3: C++ Project Restaurant

cout<<"\tOnion Parantha ";cout<<"\t 0.50 $";

cout<<"\n 9 ";cout<<"\tPlain Naan ";cout<<"\t 0.25 $ ";

cout<<"\n 10 ";cout<<"\tButter Naan ";cout<<"\t 0.41 $ ";

gotoxy(10, 19);cout<<"Chinese";

cout<<"\n 11 ";cout<<"\tVeg Chowmine ";cout<<"\t 1.60 $";

cout<<"\n 12 ";cout<<"\tVeg Manchurian ";cout<<"\t 1.41 $";

cout<<"\n 13 ";cout<<"\tSpring Rolls ";cout<<"\t 0.80 $";

cout<<"\n 14 ";cout<<"\tFried Rice ";cout<<"\t 0.60 $";

gotoxy(45 , 7);cout<<"South Indian ";

gotoxy(40, 8);cout<<" 15 ";gotoxy(45, 8);cout<<"\tPlain Dosa ";cout<<"\t 0.30 $";

gotoxy(40, 9);cout<<" 16 ";gotoxy(45, 9);cout<<"\tMasala Dosa ";cout<<"\t 0.75 $";

Page 4: C++ Project Restaurant

gotoxy(40, 10);cout<<" 17 ";gotoxy(45, 10);cout<<"\tVada Samber ";cout<<"\t 0.50 $ ";

gotoxy(45, 11);cout<<"Snacks and Fast Food ";

gotoxy(40, 12);cout<<" 18 ";gotoxy(45, 12);cout<<"\tVeg Sandwich ";cout<<"\t 0.30 $";

gotoxy(40, 13);cout<<" 19 ";gotoxy(45, 13);cout<<"\tVeg Burger ";cout<<"\t 0.80 $";

gotoxy(40, 14);cout<<" 20 ";gotoxy(45, 14);cout<<"\tPizza ";cout<<"\t\t 2.50 $";

gotoxy(45, 15);cout<<"Non-Veg ";

gotoxy(40, 16);cout<<" 21 ";gotoxy(45, 16);cout<<"\tChicke Tikka ";cout<<"\t 4.60 $";

gotoxy(40, 17);cout<<" 22 ";gotoxy(45, 17);cout<<"\tButter Chicken ";cout<<"\t 6.60 $";

gotoxy(40, 18);cout<<" 23 ";gotoxy(45, 18);

Page 5: C++ Project Restaurant

cout<<"\tFish Fry ";cout<<"\t 8.00 $";

gotoxy(45, 19);cout<<"Soups ";

gotoxy(40, 20);cout<<" 24 ";gotoxy(45, 20);cout<<"\tTomato Soup ";cout<<"\t 2.00 $";

gotoxy(40, 21);cout<<" 25 ";gotoxy(45, 21);cout<<"\tVeg Soup ";cout<<"\t 1.80 $";

gotoxy(40, 22);cout<<" 26 ";gotoxy(45, 22);cout<<"\tSweet Corn ";cout<<"\t 1.00 $ ";

gotoxy(40, 23);cout<<" 27 ";gotoxy(45, 23);cout<<"\tMushroom Soup ";cout<<"\t 2.30 $";

cout<<"\nItem "<<i+1<<" :";i++;cout<<" Code No. : ";cin>>codeno;if(codeno==1){

cout<<"\t Name : Dal Makhani ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*1.50;cout<<"\t Total : "<<amt1;

}if(codeno==2)

Page 6: C++ Project Restaurant

{cout<<"\t Name : Rajma ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*1.30;cout<<"\t Total : "<<amt1;

}if(codeno==3){

cout<<"\t Name : Shahi Paneer ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*2.10;cout<<"\t Total : "<<amt1;

}if(codeno==4){

cout<<"\t Name : Sarson sa saag ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*2.10;cout<<"\t Total : "<<amt1;

}if(codeno==5){

cout<<"\t Name : Plain Roti ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.06;cout<<"\t Total : "<<amt1;

}if(codeno==6){

cout<<"\t Name : Butter Roti ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.11;cout<<"\t Total : "<<amt1;

}if(codeno==7){

cout<<"\t Name : Aloo Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.41;

Page 7: C++ Project Restaurant

cout<<"\t Total : "<<amt1;}if(codeno==8){

cout<<"\t Name : Onion Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.50;cout<<"\t Total : "<<amt1;

}if(codeno==9){

cout<<"\t Name : Plain Naan ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.25;cout<<"\t Total : "<<amt1;

}if(codeno==10){

cout<<"\t Name : Butter Naan ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.41;cout<<"\t Total : "<<amt1;

}if(codeno==11){

cout<<"\t Name : Veg Chowmine ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*1.60;cout<<"\t Total : "<<amt1;

}if(codeno==12){

cout<<"\t Name : Veg Manchurian ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*1.41;cout<<"\t Total : "<<amt1;

}if(codeno==13){

cout<<"\t Name : Spring Roll ";

Page 8: C++ Project Restaurant

cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.80;cout<<"\t Total : "<<amt1;

}if(codeno==14){

cout<<"\t Name : Fried Rice ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.60;cout<<"\t Total : "<<amt1;

}if(codeno==15){

cout<<"\t Name : Plain Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.30;cout<<"\t Total : "<<amt1;

}if(codeno==16){

cout<<"\t Name : Masala Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.75;cout<<"\t Total : "<<amt1;

}if(codeno==17){

cout<<"\t Name : Vada Samber ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.50;cout<<"\t Total : "<<amt1;

}if(codeno==18){

cout<<"\t Name : Veg Sandwich ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.30;cout<<"\t Total : "<<amt1;

}

Page 9: C++ Project Restaurant

if(codeno==19){

cout<<"\t Name : Veg Burger ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*0.80;cout<<"\t Total : "<<amt1;

}if(codeno==20){

cout<<"\t Name : Pizza ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*2.50;cout<<"\t Total : "<<amt1;

}if(codeno==21){

cout<<"\t Name : Chicken Tikka ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*4.60;cout<<"\t Total : "<<amt1;

}if(codeno==22){

cout<<"\t Name : Butter Chicken ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*6.60;cout<<"\t Total : "<<amt1;

}if(codeno==23){

cout<<"\t Name : Fish Fry ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*8.00;cout<<"\t Total : "<<amt1;

}

if(codeno==24){

cout<<"\t Name : Tomato Soup ";cout<<"\n\t Qty : ";

Page 10: C++ Project Restaurant

cin>>qty;amt1=qty*2.00;cout<<"\t Total : "<<amt1;

}if(codeno==25){

cout<<"\t Name : Veg Soup ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*1.80;cout<<"\t Total : "<<amt1;

}if(codeno==26){

cout<<"\t Name : Sweet Corn ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*1.00;cout<<"\t Total : "<<amt1;

}if(codeno==27){

cout<<"\t Name : Mushroom Soup ";cout<<"\n\t Qty : ";cin>>qty;amt1=qty*2.30;cout<<"\t Total : "<<amt1;

}

{cout<<"\nDo you want anything else ? (y/n) : ";cin>>ch;if(ch=='n'||ch=='N'){

gt=amt1;cout<<"\nGrand Total : "<<gt<<" $";if(gt>=16){

cout<<"\nCongratulations you got 10% discount on purchasing food items for\nmore than 16 $ !!!";

int gt1=0.9*gt;cout<<"\n\nNew Grand Total : "<<gt1<<" $";

}

Page 11: C++ Project Restaurant

if(gt<16){

cout<<"\nGrand Total : "<<gt<<" $";}cout<<"\n\nThanks For Visiting !!!!";

}if(ch=='y'||ch=='Y'){

cout<<"\nItem "<<i+1<<" :";i++;cout<<" Code No. : ";cin>>codeno;if(codeno==1){

cout<<"\t Name : Dal Makhani ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*1.50;cout<<"\t Total : "<<amt2;

}if(codeno==2){

cout<<"\t Name : Rajma ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*1.30;cout<<"\t Total : "<<amt2;

}if(codeno==3){

cout<<"\t Name : Shahi Paneer ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*2.10;cout<<"\t Total : "<<amt2;

}if(codeno==4){

cout<<"\t Name : Sarson Ka Saag ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*2.10;cout<<"\t Total : "<<amt2;

Page 12: C++ Project Restaurant

}if(codeno==5){

cout<<"\t Name : Plain Roti ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.06;cout<<"\t Total : "<<amt2;

}if(codeno==6){

cout<<"\t Name : Butter Roti ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.11;cout<<"\t Total : "<<amt2;

}if(codeno==7){

cout<<"\t Name : Aloo Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.41;cout<<"\t Total : "<<amt2;

}if(codeno==8){

cout<<"\t Name : Onion Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.50;cout<<"\t Total : "<<amt2;

}if(codeno==9){

cout<<"\t Name : Plain Naan ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.25;cout<<"\t Total : "<<amt2;

}if(codeno==10){

cout<<"\t Name : Butter Naan ";cout<<"\n\t Qty : ";

Page 13: C++ Project Restaurant

cin>>qty;amt2=qty*0.41;cout<<"\t Total : "<<amt2;

}if(codeno==11){

cout<<"\t Name : Veg Chowmine ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*1.60;cout<<"\t Total : "<<amt2;

}if(codeno==12){

cout<<"\t Name : Veg Manchurian ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*1.41;cout<<"\t Total : "<<amt2;

}if(codeno==13){

cout<<"\t Name : Spring Roll ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.80;cout<<"\t Total : "<<amt2;

}if(codeno==14){

cout<<"\t Name : Fried Rice ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.60;cout<<"\t Total : "<<amt2;

}if(codeno==15){

cout<<"\t Name : Plain Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.30;cout<<"\t Total : "<<amt2;

}if(codeno==16)

Page 14: C++ Project Restaurant

{cout<<"\t Name : Masala Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.75;cout<<"\t Total : "<<amt2;

}if(codeno==17){

cout<<"\t Name : Vada Samber ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.50;cout<<"\t Total : "<<amt2;

}if(codeno==18){

cout<<"\t Name : Veg Sandwich ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.30;cout<<"\t Total : "<<amt2;

}if(codeno==19){

cout<<"\t Name : Veg Burger ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*0.80;cout<<"\t Total : "<<amt2;

}if(codeno==20){

cout<<"\t Name : Pizza ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*2.50;cout<<"\t Total : "<<amt2;

}if(codeno==21){

cout<<"\t Name : Chicken Tikka ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*4.60;

Page 15: C++ Project Restaurant

cout<<"\t Total : "<<amt2;}if(codeno==22){

cout<<"\t Name : Butter Chicken ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*6.60;cout<<"\t Total : "<<amt2;

}if(codeno==23){

cout<<"\t Name : Fish Fry ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*8.00;cout<<"\t Total : "<<amt2;

}if(codeno==24){

cout<<"\t Name : Tomato Soup ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*2.00;cout<<"\t Total : "<<amt2;

}if(codeno==25){

cout<<"\t Name : Veg Soup ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*1.80;cout<<"\t Total : "<<amt2;

}if(codeno==26){

cout<<"\t Name : Sweet Corn ";cout<<"\n\t Qty : ";cin>>qty;amt2=qty*1.00;cout<<"\t Total : "<<amt2;

}if(codeno==27){

cout<<"\t Name : Mushroom Soup ";

Page 16: C++ Project Restaurant

cout<<"\n\t Qty : ";cin>>qty;amt2=qty*2.30;cout<<"\t Total : "<<amt2;

}

cout<<"\nDo you want anything else ? (y/n) : ";cin>>ch;if(ch=='n'||ch=='N'){

gt=amt1+amt2;cout<<"\nGrand Total : "<<gt<<" $";if(gt>=16){

cout<<"\nCongratulations you got 10% discount on purchasing food items for\nmore than 16 $ !!!";

int gt1=0.9*gt;cout<<"\n\nNew Grand Total : "<<gt1<<" $";

}if(gt<16){

cout<<"\nGrand Total : "<<gt<<" $";}cout<<"\n\nThanks For Visiting !!!!";

}if(ch=='y'||ch=='Y'){

cout<<"\nItem "<<i+1<<" :";i++;cout<<" Code No. : ";cin>>codeno;if(codeno==1){

cout<<"\t Name : Dal Makhani ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*1.50;cout<<"\t Total : "<<amt3;

}if(codeno==2){

cout<<"\t Name : Rajma ";cout<<"\n\t Qty : ";

Page 17: C++ Project Restaurant

cin>>qty;amt3=qty*1.30;cout<<"\t Total : "<<amt3;

}if(codeno==3){

cout<<"\t Name : Shahi Paneer ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*2.10;cout<<"\t Total : "<<amt3;

}if(codeno==4){

cout<<"\t Name : Sarson Ka Saag ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*2.10;cout<<"\t Total : "<<amt3;

}if(codeno==5){

cout<<"\t Name : Plain Roti ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.06;cout<<"\t Total : "<<amt3;

}if(codeno==6){

cout<<"\t Name : Butter Roti ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.11;cout<<"\t Total : "<<amt3;

}if(codeno==7){

cout<<"\t Name : Aloo Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.41;cout<<"\t Total : "<<amt3;

}if(codeno==8)

Page 18: C++ Project Restaurant

{cout<<"\t Name : Onion Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.50;cout<<"\t Total : "<<amt3;

}if(codeno==9){

cout<<"\t Name : Plain Naan ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.25;cout<<"\t Total : "<<amt3;

}if(codeno==10){

cout<<"\t Name : Butter Naan ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.41;cout<<"\t Total : "<<amt3;

}if(codeno==11){

cout<<"\t Name : Veg Chowmine ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*1.60;cout<<"\t Total : "<<amt3;

}if(codeno==12){

cout<<"\t Name : Veg Manchurian ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*1.41;cout<<"\t Total : "<<amt3;

}if(codeno==13){

cout<<"\t Name : Spring Roll ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.80;

Page 19: C++ Project Restaurant

cout<<"\t Total : "<<amt3;}if(codeno==14){

cout<<"\t Name : Fried Rice ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.60;cout<<"\t Total : "<<amt3;

}if(codeno==15){

cout<<"\t Name : Plain Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.30;cout<<"\t Total : "<<amt3;

}if(codeno==16){

cout<<"\t Name : Masala Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.75;cout<<"\t Total : "<<amt3;

}if(codeno==17){

cout<<"\t Name : Vada Samber ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.50;cout<<"\t Total : "<<amt3;

}if(codeno==18){

cout<<"\t Name : Veg Sandwich ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.30;cout<<"\t Total : "<<amt3;

}if(codeno==19){

cout<<"\t Name : Veg Burger ";

Page 20: C++ Project Restaurant

cout<<"\n\t Qty : ";cin>>qty;amt3=qty*0.80;cout<<"\t Total : "<<amt3;

}if(codeno==20){

cout<<"\t Name : Pizza ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*2.50;cout<<"\t Total : "<<amt3;

}if(codeno==21){

cout<<"\t Name : Chicken Tikka ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*4.60;cout<<"\t Total : "<<amt3;

}if(codeno==22){

cout<<"\t Name : Butter Chicken ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*6.60;cout<<"\t Total : "<<amt3;

}if(codeno==23){

cout<<"\t Name : Fish Fry ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*8.00;cout<<"\t Total : "<<amt3;

}if(codeno==24){

cout<<"\t Name : Tomato Soup ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*2.00;cout<<"\t Total : "<<amt3;

}

Page 21: C++ Project Restaurant

if(codeno==25){

cout<<"\t Name : Veg Soup ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*1.80;cout<<"\t Total : "<<amt3;

}if(codeno==26){

cout<<"\t Name : Sweet Corn ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*1.00;cout<<"\t Total : "<<amt3;

}if(codeno==27){

cout<<"\t Name : Mushroom Soup ";cout<<"\n\t Qty : ";cin>>qty;amt3=qty*2.30;cout<<"\t Total : "<<amt3;

}

cout<<"\nDo you want anything else ? (y/n) : ";cin>>ch;if(ch=='n'||ch=='N'){

gt=amt1+amt2+amt3;cout<<"\nGrand Total : "<<gt<<" $";if(gt>=16){

cout<<"\nCongratulations you got 10% discount on purchasing food items for\nmore than 16 $ !!!";

int gt1=0.9*gt;cout<<"\n\nNew Grand Total : "<<gt1<<" $";

}if(gt<16){

cout<<"\nGrand Total : "<<gt<<" $";}

cout<<"\n\nThanks For Visiting !!!!";

Page 22: C++ Project Restaurant

}if(ch=='y'||ch=='Y'){

cout<<"\nItem "<<i+1<<" :";i++;cout<<" Code No. : ";cin>>codeno;if(codeno==1){

cout<<"\t Name : Dal Makhani ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*1.50;cout<<"\t Total : "<<amt4;

}if(codeno==2){

cout<<"\t Name : Rajma ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*1.30;cout<<"\t Total : "<<amt4;

}if(codeno==3){

cout<<"\t Name : Shahi Paneer ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*2.10;cout<<"\t Total : "<<amt4;

}if(codeno==4){

cout<<"\t Name : Sarson Ka Saag ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*2.10;cout<<"\t Total : "<<amt4;

}if(codeno==5){

cout<<"\t Name : Plain Roti ";cout<<"\n\t Qty : ";cin>>qty;

Page 23: C++ Project Restaurant

amt4=qty*0.06;cout<<"\t Total : "<<amt4;

}if(codeno==6){

cout<<"\t Name : Butter Roti ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.11;cout<<"\t Total : "<<amt4;

}if(codeno==7){

cout<<"\t Name : Aloo Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.41;cout<<"\t Total : "<<amt4;

}if(codeno==8){

cout<<"\t Name : Onion Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.50;cout<<"\t Total : "<<amt4;

}if(codeno==9){

cout<<"\t Name : Plain Naan ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.25;cout<<"\t Total : "<<amt4;

}if(codeno==10){

cout<<"\t Name : Butter Naan ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.41;cout<<"\t Total : "<<amt4;

}if(codeno==11){

Page 24: C++ Project Restaurant

cout<<"\t Name : Veg Chowmine ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*1.60;cout<<"\t Total : "<<amt4;

}if(codeno==12){

cout<<"\t Name : Veg Manchurian ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*1.41;cout<<"\t Total : "<<amt4;

}if(codeno==13){

cout<<"\t Name : Spring Roll ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.80;cout<<"\t Total : "<<amt4;

}if(codeno==14){

cout<<"\t Name : Fried Rice ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.60;cout<<"\t Total : "<<amt4;

}if(codeno==15){

cout<<"\t Name : Plain Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.30;cout<<"\t Total : "<<amt4;

}if(codeno==16){

cout<<"\t Name : Masala Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.75;cout<<"\t Total : "<<amt4;

Page 25: C++ Project Restaurant

}if(codeno==17){

cout<<"\t Name : Vada Samber ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.50;cout<<"\t Total : "<<amt4;

}if(codeno==18){

cout<<"\t Name : Veg Sandwich ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.30;cout<<"\t Total : "<<amt4;

}if(codeno==19){

cout<<"\t Name : Veg Burger ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*0.80;cout<<"\t Total : "<<amt4;

}if(codeno==20){

cout<<"\t Name : Pizza ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*2.50;cout<<"\t Total : "<<amt4;

}if(codeno==21){

cout<<"\t Name : Chicken Tikka ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*4.60;cout<<"\t Total : "<<amt4;

}if(codeno==22){

cout<<"\t Name : Butter Chicken ";cout<<"\n\t Qty : ";

Page 26: C++ Project Restaurant

cin>>qty;amt4=qty*6.60;cout<<"\t Total : "<<amt4;

}if(codeno==23){

cout<<"\t Name : Fish Fry ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*8.00;cout<<"\t Total : "<<amt4;

}if(codeno==24){

cout<<"\t Name : Tomato Soup ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*2.00;cout<<"\t Total : "<<amt4;

}if(codeno==25){

cout<<"\t Name : Veg Soup ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*1.80;cout<<"\t Total : "<<amt4;

}if(codeno==26){

cout<<"\t Name : Sweet Corn ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*1.00;cout<<"\t Total : "<<amt4;

}if(codeno==27){

cout<<"\t Name : Mushroom Soup ";cout<<"\n\t Qty : ";cin>>qty;amt4=qty*2.30;cout<<"\t Total : "<<amt4;

}

Page 27: C++ Project Restaurant

cout<<"\nDo you want anything else ? (y/n) : ";cin>>ch;if(ch=='n'||ch=='N'){

gt=amt1+amt2+amt3+amt4;cout<<"\nGrand Total : "<<gt<<" $";if(gt>=16){

cout<<"\nCongratulations you got 10% discount on purchasing food items for\nmore than 16 $ !!!";

int gt1=0.9*gt;cout<<"\n\nNew Grand Total : "<<gt1<<" $";

}if(gt<16){

cout<<"\nGrand Total : "<<gt<<" $";}

cout<<"\n\nThanks For Visiting !!!!";}if(ch=='y'||ch=='Y'){

cout<<"\nItem "<<i+1<<" :";i++;cout<<" Code No. : ";cin>>codeno;if(codeno==1){

cout<<"\t Name : Dal Makhani ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*1.50;cout<<"\t Total : "<<amt5;

}if(codeno==2){

cout<<"\t Name : Rajma ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*1.30;cout<<"\t Total : "<<amt5;

}if(codeno==3){

Page 28: C++ Project Restaurant

cout<<"\t Name : Shahi Paneer ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*2.10;cout<<"\t Total : "<<amt5;

}if(codeno==4){

cout<<"\t Name : Sarson Ka Saag ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*2.10;cout<<"\t Total : "<<amt5;

}if(codeno==5){

cout<<"\t Name : Plain Roti ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.06;cout<<"\t Total : "<<amt5;

}if(codeno==6){

cout<<"\t Name : Butter Roti ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.11;cout<<"\t Total : "<<amt5;

}if(codeno==7){

cout<<"\t Name : Aloo Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.41;cout<<"\t Total : "<<amt5;

}if(codeno==8){

cout<<"\t Name : Onion Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.50;cout<<"\t Total : "<<amt5;

Page 29: C++ Project Restaurant

}if(codeno==9){

cout<<"\t Name : Plain Naan ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.25;cout<<"\t Total : "<<amt5;

}if(codeno==10){

cout<<"\t Name : Butter Naan ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.41;cout<<"\t Total : "<<amt5;

}if(codeno==11){

cout<<"\t Name : Veg Chowmine ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*1.60;cout<<"\t Total : "<<amt5;

}if(codeno==12){

cout<<"\t Name : Veg Manchurian ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*1.41;cout<<"\t Total : "<<amt5;

}if(codeno==13){

cout<<"\t Name : Spring Roll ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.80;cout<<"\t Total : "<<amt5;

}if(codeno==14){

cout<<"\t Name : Fried Rice ";cout<<"\n\t Qty : ";

Page 30: C++ Project Restaurant

cin>>qty;amt5=qty*0.60;cout<<"\t Total : "<<amt5;

}if(codeno==15){

cout<<"\t Name : Plain Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.30;cout<<"\t Total : "<<amt5;

}if(codeno==16){

cout<<"\t Name : Masala Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.75;cout<<"\t Total : "<<amt5;

}if(codeno==17){

cout<<"\t Name : Vada Samber ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.50;cout<<"\t Total : "<<amt5;

}if(codeno==18){

cout<<"\t Name : Veg Sandwich ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.30;cout<<"\t Total : "<<amt5;

}if(codeno==19){

cout<<"\t Name : Veg Burger ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*0.80;cout<<"\t Total : "<<amt5;

}if(codeno==20)

Page 31: C++ Project Restaurant

{cout<<"\t Name : Pizza ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*2.50;cout<<"\t Total : "<<amt5;

}if(codeno==21){

cout<<"\t Name : Chicken Tikka ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*4.60;cout<<"\t Total : "<<amt5;

}if(codeno==22){

cout<<"\t Name : Butter Chicken ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*6.60;cout<<"\t Total : "<<amt5;

}if(codeno==23){

cout<<"\t Name : Fish Fry ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*8.00;cout<<"\t Total : "<<amt5;

}if(codeno==24){

cout<<"\t Name : Tomato Soup ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*2.00;cout<<"\t Total : "<<amt5;

}if(codeno==25){

cout<<"\t Name : Veg Soup ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*1.80;

Page 32: C++ Project Restaurant

cout<<"\t Total : "<<amt5;}if(codeno==26){

cout<<"\t Name : Sweet Corn ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*1.00;cout<<"\t Total : "<<amt5;

}if(codeno==27){

cout<<"\t Name : Mushroom Soup ";cout<<"\n\t Qty : ";cin>>qty;amt5=qty*2.30;cout<<"\t Total : "<<amt5;

}cout<<"\nDo you want anything else ? (y/n) : ";

cin>>ch;if(ch=='n'||ch=='N'){

gt=amt1+amt2+amt3+amt4+amt5;cout<<"\nGrand Total : "<<gt<<" $";if(gt>=16){

cout<<"\nCongratulations you got 10% discount on purchasing food items for\nmore than 16 $ !!!";

int gt1=0.9*gt;cout<<"\n\nNew Grand Total : "<<gt1<<" $";

}if(gt<16){

cout<<"\nGrand Total : "<<gt<<" $";}

cout<<"\n\nThanks For Visiting !!!!";}if(ch=='y'||ch=='Y'){

cout<<"\nItem "<<i+1<<" :";i++;cout<<" Code No. : ";cin>>codeno;

Page 33: C++ Project Restaurant

if(codeno==1){

cout<<"\t Name : Dal Makhani ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*1.50;cout<<"\t Total : "<<amt6;

}if(codeno==2){

cout<<"\t Name : Rajma ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*1.30;cout<<"\t Total : "<<amt6;

}if(codeno==3){

cout<<"\t Name : Shahi Paneer ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*2.10;cout<<"\t Total : "<<amt6;

}if(codeno==4){

cout<<"\t Name : Sarson Ka Saag ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*2.10;cout<<"\t Total : "<<amt6;

}if(codeno==5){

cout<<"\t Name : Plain Roti ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.06;cout<<"\t Total : "<<amt6;

}if(codeno==6){

cout<<"\t Name : Butter Roti ";cout<<"\n\t Qty : ";cin>>qty;

Page 34: C++ Project Restaurant

amt6=qty*0.11;cout<<"\t Total : "<<amt6;

}if(codeno==7){

cout<<"\t Name : Aloo Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.41;cout<<"\t Total : "<<amt6;

}if(codeno==8){

cout<<"\t Name : Onion Parantha ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.50;cout<<"\t Total : "<<amt6;

}if(codeno==9){

cout<<"\t Name : Plain Naan ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.25;cout<<"\t Total : "<<amt6;

}if(codeno==10){

cout<<"\t Name : Butter Naan ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.41;cout<<"\t Total : "<<amt6;

}if(codeno==11){

cout<<"\t Name : Veg Chowmine ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*1.60;cout<<"\t Total : "<<amt6;

}if(codeno==12){

Page 35: C++ Project Restaurant

cout<<"\t Name : Veg Manchurian ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*1.41;cout<<"\t Total : "<<amt6;

}if(codeno==13){

cout<<"\t Name : Spring Roll ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.80;cout<<"\t Total : "<<amt6;

}if(codeno==14){

cout<<"\t Name : Fried Rice ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.60;cout<<"\t Total : "<<amt6;

}if(codeno==15){

cout<<"\t Name : Plain Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.30;cout<<"\t Total : "<<amt6;

}if(codeno==16){

cout<<"\t Name : Masala Dosa ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.75;cout<<"\t Total : "<<amt6;

}if(codeno==17){

cout<<"\t Name : Vada Samber ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.50;cout<<"\t Total : "<<amt6;

Page 36: C++ Project Restaurant

}if(codeno==18){

cout<<"\t Name : Veg Sandwich ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.30;cout<<"\t Total : "<<amt6;

}if(codeno==19){

cout<<"\t Name : Veg Burger ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*0.80;cout<<"\t Total : "<<amt6;

}if(codeno==20){

cout<<"\t Name : Pizza ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*2.50;cout<<"\t Total : "<<amt6;

}if(codeno==21){

cout<<"\t Name : Chicken Tikka ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*4.60;cout<<"\t Total : "<<amt6;

}if(codeno==22){

cout<<"\t Name : Butter Chicken ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*6.60;cout<<"\t Total : "<<amt6;

}if(codeno==23){

cout<<"\t Name : Fish Fry ";cout<<"\n\t Qty : ";

Page 37: C++ Project Restaurant

cin>>qty;amt6=qty*8.00;cout<<"\t Total : "<<amt6;

}if(codeno==24){

cout<<"\t Name : Tomato Soup ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*2.00;cout<<"\t Total : "<<amt6;

}if(codeno==25){

cout<<"\t Name : Veg Soup ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*1.80;cout<<"\t Total : "<<amt6;

}if(codeno==26){

cout<<"\t Name : Sweet Corn ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*1.00;cout<<"\t Total : "<<amt6;

}if(codeno==27){

cout<<"\t Name : Mushroom Soup ";cout<<"\n\t Qty : ";cin>>qty;amt6=qty*2.30;cout<<"\t Total : "<<amt6;

}cout<<"\nDo you want anything else ? (y/n) : ";

cin>>ch;if(ch=='n'||ch=='N'){

gt=amt1+amt2+amt3+amt4+amt5+amt6;cout<<"\nGrand Total : "<<gt<<" $";if(gt>=16){

Page 38: C++ Project Restaurant

cout<<"\nCongratulations you got 10% discount on purchasing food items for\nmore than 16 $ !!!";

int gt1=0.9*gt;cout<<"\n\nNew Grand Total : "<<gt1<<" $";

}if(gt<16){

cout<<"\nGrand Total : "<<gt<<" $";}

cout<<"\n\nThanks For Visiting !!!!";}

}}}}}}}}

getch();}

Page 39: C++ Project Restaurant

BIBLIOGRAPHY

The following helped in making my project :

1. Books :i) Sumita Arora ii) Turbo c++ - Written by Robert

Lafore.