Guest User

Untitled

a guest
Oct 17th, 2018
102
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. menu_list = open("menu.txt", "w+")
  2.  
  3.  
  4. print ("Your restaurant menu")
  5. menu_list.write("Your restaurant menu ")
  6.  
  7. while True:
  8. menu = input ("Please enter your daily menu to the list ")
  9. menu_list.write(str(menu))
  10. #Can't find out how we can list the menues and costs on seperate lines in the text file
  11.  
  12. price = int(input ("Please enter the price of the menu: "))
  13. menu_list.write(str(price))
  14.  
  15. choice = input("Do you want to add another menu to the list? Yes/No ").lower()
  16. if choice == "no":
  17. break
  18.  
  19. menu_list.close()
Add Comment
Please, Sign In to add comment