IMPORTANT SOURCE CODE Reduced

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 15

SOURCE CODE

import pandas as pd

import numpy as np

self_tamt1=0

self_tamt2=0

self_tamt3=0

self_tamt4=0

self_amt=0

print(' '*60,"______Welcome to resturant management system______")

print()

print()

vegstarter=pd.read_csv("D:/ip project/Veg_starrer.csv")

vegmain=pd.read_csv("D:/ip project/Veg_main course.csv")

nonvegstarter=pd.read_csv("D:/ip project/Non_veg starrer.csv")

nonvegmain=pd.read_csv("D:/ip project/Non_veg main course.csv")

print(vegstarter)

print()

print(nonvegstarter)

print()

print(vegmain)

print()

print(nonvegmain)

print()

option=int(input("Press 1:To add new order\nPress 2: Add new dish\nPress 3: Remove a dish\n"))

while option==1:

print()

veg_or_nonveg=int(input("Press 1:To order veg item\nPress 2:To order non veg iteml\n"))

if veg_or_nonveg==1:

a=int(input("Press 1:To view starter menu\nPress 2:To view main course\n"))


if a==1:

print("Welcome to starter menu")

print(vegstarter)

orderno=int(input("Enter your with order number:\n"))

qty=int(input("Enter the quantity:\n"))

if(orderno==1):

self_amt=qty*110

if(orderno==2):

self_amt=qty*100

if(orderno==3):

self_amt=qty*98

if(orderno==4):

self_amt=qty*110

if(orderno==5):

self_amt=qty*10

if(orderno==6):

self_amt=qty*110

if(orderno==7):

self_amt=qty*110

if(orderno==8):

self_amt=qty*110

if(orderno==9):

self_amt=qty*110

if(orderno==10):

self_amt=qty*110

self_tamt1=self_tamt1+self_amt

bill=int(input("Press 1: To view main menu\nPress 2: To view bill\n"))

if bill==1:

continue

else :

break

if a==2:

print("Welcome to main course menu")


print(vegmain)

orderno=int(input("Enter your with order number:\n"))

qty=int(input("Enter the quantity:\n"))

if(orderno==1):

self_amt=qty*110

if(orderno==2):

self_amt=qty*100

if(orderno==3):

self_amt=qty*98

if(orderno==4):

self_amt=qty*110

if(orderno==5):

self_amt=qty*10

if(orderno==6):

self_amt=qty*110

if(orderno==7):

self_amt=qty*110

if(orderno==8):

self_amt=qty*110

if(orderno==9):

self_amt=qty*110

if(orderno==10):

self_amt=qty*110

self_tamt2=self_tamt2+self_amt

bill=int(input("Press 1: To view main menu\nPress 2: To view bill\n"))

if bill==1:

continue

else :

break

if veg_or_nonveg==2:

a=int(input("Press 1:To view starter menu\nPress 2:To view main course\n"))

if a==1:

print("Welcome to starter menu")


print(nonvegstarter)

orderno=int(input("Enter your with order number:\n"))

qty=int(input("Enter the quantity:\n"))

if(orderno==1):

self_amt=qty*110

if(orderno==2):

self_amt=qty*100

if(orderno==3):

self_amt=qty*98

if(orderno==4):

self_amt=qty*110

if(orderno==5):

self_amt=qty*10

if(orderno==6):

self_amt=qty*110

if(orderno==7):

self_amt=qty*110

if(orderno==8):

self_amt=qty*110

if(orderno==9):

self_amt=qty*110

if(orderno==10):

self_amt=qty*110

self_tamt3=self_tamt3+self_amt

bill=int(input("Press 1: To view main menu\nPress 2: To view bill\n"))

if bill==1:

continue

else :

break

if a==2:

print("Welcome to main course menu")

print(nonvegmain)

orderno=int(input("Enter your with order number:\n"))


qty=int(input("Enter the quantity:\n"))

if(orderno==1):

self_amt=qty*110

if(orderno==2):

self_amt=qty*100

if(orderno==3):

self_amt=qty*98

if(orderno==4):

self_amt=qty*110

if(orderno==5):

self_amt=qty*10

if(orderno==6):

self_amt=qty*110

if(orderno==7):

self_amt=qty*110

if(orderno==8):

self_amt=qty*110

if(orderno==9):

self_amt=qty*110

if(orderno==10):

self_amt=qty*110

self_tamt4=self_tamt4+self_amt

bill=int(input("Press 1: To view main menu\nPress 2: To view bill\n"))

if bill==1:

continue

else :

break

print(self_tamt1)

print(self_tamt2)

print(self_tamt3)

print(self_tamt4)

print("*****************Resturant plaza***************")

print("Total cost of starter:",self_tamt1+self_tamt3)


print("Total cost of main course:",self_tamt2+self_tamt4)

print("Total amount:",self_tamt1+self_tamt2+self_tamt3+self_tamt4)

gst=(self_tamt1*18)/100+(self_tamt2*18)/100+(self_tamt3*18)/100+(self_tamt4*18)/100

print("Total GST:",gst)

print("Net Amount:",self_tamt1+self_tamt2+self_tamt3+self_tamt4+gst)

print("…………………Thanks for choosing our resturant……………………")

print("……………………………Visit again!!!!!!………………………………………")

while option==2:

veg_or_nonveg=int(input("Press 1:To enter veg item\nPress 2:To enter non veg iteml\n"))

if veg_or_nonveg==1:

a=int(input("Press 1:To enter new dish in starter menu\nPress 2:To enter new dish new dish in main course\n"))

if a==1:

n=int(input("Enter the orderno of new dish:"))

rollno=int(input("Enter the S.No.:"))

dishname=input("Enter dish name:")

price=int(input("Enter the price of dish:"))

vegstarter.loc[n]=[rollno,dishname,price]

vegstarter.to_csv("/storage/emulated/0/Veg_starrer.csv",header=False,index=False)

print(vegstarter)

q=int(input("Press 1:To add more dishes\nPress 2: To exit"))

if q==1:

continue

else :

break

if a==2:

n=int(input("Enter the orderno of new dish:"))

rollno=int(input("Enter the S.No.:"))

dishname=input("Enter dish name:")

price=int(input("Enter the price of dish:"))

vegmain.loc[n]=[rollno,dishname,price]

vegmain.to_csv("/storage/emulated/0/Veg_main course.csv",header=False,index=False)

print(vegmain)

q=int(input("Press 1:To add more dishes\nPress 2: To exit"))


if q==1:

continue

else :

break

if veg_or_nonveg==2:

a=int(input("Press 1:To enter new dish in starter menu\nPress 2:To enter new dish new dish in main course\n"))

if a==1:

n=int(input("Enter the orderno of new dish:"))

rollno=int(input("Enter the S.No.:"))

dishname=input("Enter dish name:")

price=int(input("Enter the price of dish:"))

nonvegstarter.loc[n]=[rollno,dishname,price]

nonvegstarter.to_csv("/storage/emulated/0/Non_veg starrer.csv",header=False,index=False)

print(nonvegstarter)

q=int(input("Press 1:To add more dishes\nPress 2: To exit"))

if q==1:

continue

else :

break

if a==2:

n=int(input("Enter the orderno of new dish:"))

rollno=int(input("Enter the S.No.:"))

dishname=input("Enter dish name:")

price=int(input("Enter the price of dish:"))

nonvegmain.loc[n]=[rollno,dishname,price]

nonvegmain.to_csv("/storage/emulated/0/Non_veg main course.csv",header=False,index=False)

print(nonvegmain)

q=int(input("Press 1:To add more dishes\nPress 2: To exit"))

if q==1:

continue

else :

break

while option==3:
veg_or_nonveg=int(input("Press 1:To delete veg item\nPress 2:To delete non veg iteml\n"))

if veg_or_nonveg==1:

a=int(input("Press 1:To delete a dish in starter menu\nPress 2:To delete a dish in main course\n"))

if a==1:

m=int(input("Enter the order no. to be deleted from list:\n"))

vegstarter.drop([m])

vegstarter.to_csv("/storage/emulated/0/Veg_starrer.csv",header=False,index=False)

print(vegstarter)

p=int(input("Press 1:To deletemore dishes\nPress 2: To exit\n"))

if p==1:

continue

else :

break

if a==2:

m=int(input("Enter the order no. to be deleted from list:\n"))

vegmain.drop([m])

vegmain.to_csv("/storage/emulated/0/Veg_main course.csv",header=False,index=False)

print(vegmain)

p=int(input("Press 1:To deletemore dishes\nPress 2: To exit\n"))

if p==1:

continue

else :

break

if veg_or_nonveg==2:

a=int(input("Press 1:To enter new dish in starter menu\nPress 2:To enter new dish new dish in main course\n"))

if a==1:

m=int(input("Enter the order no. to be deleted from list:\n"))

nonvegstarter.drop([m])

nonvegstarter.to_csv("/storage/emulated/0/Non_veg starrer.csv",header=False,index=False)

print(nonvegstarter)

p=int(input("Press 1:To deletemore dishes\nPress 2: To exit\n"))

if p==1:

continue
else :

break

if a==2:

m=int(input("Enter the order no. to be deleted from list:\n"))

nonvegmain.drop([m],axis=0)

nonvegmain.to_csv("/storage/emulated/0/Non_veg main course.csv",header=False,index=False)

print(nonvegmain)

p=int(input("Press 1:To deletemore dishes\nPress 2: To exit\n"))

if p==1:

continue

else :

break

print("Here is Siddharth Chaudhary thanking you to my respected I.P. teacher 'Mr. Brajesh Kumar Singh to guide me in completing this program
successfully.......")

print("Thank you")
VEG STARTER CSV
NON-VEG MAIN COURSE CSV
NON VEG STARTER
VEG MAIN COURSE
OUTPUT FOR CODES
• IF WE WANT TO ADD ANY DISH THEN WE HAVE
TO PRESS 2

You might also like