0% found this document useful (0 votes)
15 views2 pages

Marie Fel Basi Bas

Uploaded by

hanekura.369
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
15 views2 pages

Marie Fel Basi Bas

Uploaded by

hanekura.369
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

MariefelBasibas

Reviewer:

INVENTORY 1. {"CEMENT":{"QUANTITY":100,"PRICE":459},
"BRICKS":{"QUANTITY":100,"PRICE":459},
"BRICKS":{"QUANTITY":100,"PRICE":459},
'SAND':{"QUANTITY": 2000, "PRICE": 100},
'STEEL':{"QUANTITY": 2000, "PRICE": 100},
'CONCREET':{"QUANTITY":2000, "PRICE": 100}}
print("THE INVENTORY")
for name, values in INVENTORY.items():
print("item name:",name,"QUANTITY:",values["QUANTITY"],"PRICE:",values["PRICE"])
print("\nOPERATIONS")
print("1.ADD ITEMS TO INVENTORY")
print("2.DELETE ITEMS TO INVENTORY")
print("3.EDIT ITEMS PRICE OR QUANTITY")
print("4.VIEW INVENTORY")
print("5.EXIT PROGRAM")
user_option = int(input("ENTER CHOICE (1-5): "))
if user_option 2. [1,2,3,4,5]:
print("WELCOME TO DATABASE")
if user_option 3. 1:
print("ADD ITEMS TO INVENTORY")
item_name = input("Enter Item name: ").upper()
if item_name 4. INVENTORY:
quanity = int(input("Enter Quantity of the item: "))
price = float(input("Enter the price of the item: "))
INVENTORY[item_name]={"QUANTITY":quanity,"PRICE":price}
print(f"{item_name} has been added to Inventory")
print(INVENTORY)
5.
print("The item you want to add is already part of the Inventory")
6.
print("DELETE ITEMS TO INVENTORY")
delete_item = input("Enter Item name you want to delete: ").upper()
7.
del INVENTORY[delete_item]
print(f"{delete_item} has been deleted to Inventory")
print(INVENTORY)
8.
print("The item you want to delete is not part of the Inventory")
9.
print("EDIT ITEMS PRICE OR QUANTITY IN INVENTORY")
ask = int(input("Choose what do you want to edit (1.QUANTITY 2.PRICE 3.Both): "))
10.
edit_name = input("Enter Item name you want to edit: ").upper()
11.
print("Edit the Quantity")
new_quantity = int(input("Enter new Quantity of the item: "))
INVENTORY[edit_name]["QUANTITY"]=new_quantity
print(f"{edit_name} quantity successfully edited")
print(INVENTORY)
12.
print("Item does not exist")
13.
edit_name = input("Enter Item name you want to edit: ").upper()
14.
print("Edit the Price")
new_price = int(input("Enter new PRICE of the item: "))
INVENTORY[edit_name]["PRICE"]=new_price
print(f"{edit_name} price successfully edited")
print(INVENTORY)
15.
print("Item does not exist")
16.
edit_name = input("Enter Item name you want to edit: ").upper()
17.
print("Edit both Price and quantity")
new_price = int(input("Enter new PRICE of the item: "))
new_quantity = int(input("Enter new Quantity of the item: "))
INVENTORY[edit_name]["PRICE"]=new_price
INVENTORY[edit_name]["QUANTITY"]=new_quantity
print(f"{edit_name} price and quantity successfully edited")
print(INVENTORY)
18.
print("Item does not exist")
19.
print("Select between 1-3 only")
20.
21.
print("THE INVENTORY IS EMPTY")
22.
for name, values in INVENTORY.items():
print("item
name:",name,"QUANTITY:",values["QUANTITY"],"PRICE:",values["PRICE"])
23.
print("EXIT PROGRAM")
24.
25.print("SELECT BETWEEN 1-5 ONLY")

You might also like