SHARE
TWEET

Untitled

a guest Jun 16th, 2019 52 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Record.remove("Americano")
  2. ValueError: list.remove(x): x not in list
  3.      
  4. ['Menu_name', 'Cafe_latte', 'Americano', 'Americano', 'Smoothie_queen', 'Americano', 'Americano', 'Cafe_mocha', 'Cafe_latte', 'Americano', 'Amorparty', 'Plain_yogurt', 'Americano', 'Americano', 'Cafe_mocha', 'Berry_smoothie', 'Cafe_mocha', 'Cafe_latte', 'Americano', 'Cafe_latte', 'Berry_smoothie', 'Berry_smoothie', 'Plain_yogurt', 'Berry_smoothie', 'Plane_yougurt', 'Berry_smoothie', 'Cafe_latte', 'Americano', 'Americano', 'Cafe_mocha', 'Plain_yogurt', 'Americano', 'Plain_yogurt', 'Cafe_mocha', 'Plain_yogurt', 'Americano', 'Cofe_latte', 'Plain_yogurt', 'Cafe_mocha', 'Americano', 'Berry_smoothie', 'Cafe_latte', 'Cafe_latte', 'Cafe_mocha', 'Cafe_latte', 'Cafe_latte', 'Cafe_mocha', 'Americano', 'Plain_yogurt', 'Americano', 'Americano', 'Cofe_latte', 'Berry_smoothie', 'Berry_smudie', 'American_air', 'Plain_yogurt', 'Berry_smoothie', 'Berry_smoothie', 'Berry_smoothie', 'Cafe_latte', 'Americano', 'Plain_yogurt', 'Cafe_latte', 'Cafe_mocha', 'Cafe_mocha', 'Plain_yogurt', 'Berry_smoothie', 'Berry_smoothie', 'Cafe_mocha', 'Cafe_mocha', 'Berry_smoothie', 'Cafe_mocha', 'Plain_yogurt']
  5.      
  6. def load_menu():
  7.     Menu = []
  8.     #========= STEP 1 ==========
  9.     menufile = open("menu.txt", "r")
  10.  
  11.     for line in menufile:
  12.         menu = line.split()
  13.         Menu.append(menu)
  14.  
  15.     menufile.close()
  16.  
  17.     for menu in Menu:
  18.         print(menu[0]," : ",menu[1])
  19.     #========= STEP 1 ==========
  20.     return Menu
  21.  
  22. def error_check(date):
  23.     #========= STEP 3 ==========
  24.     Record = []
  25.     recordfile = open("ledger_"+date+".txt","r")
  26.  
  27.     for line in recordfile:
  28.         record = line.split()
  29.         Record.append(record[1])
  30.         Record.remove("Americano")
  31.     print(Record)
  32.  
  33.     recordfile.close()
  34.     #========= STEP 3 ==========
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top