Professional Documents
Culture Documents
# Sample Database Using List and Tuples
# Sample Database Using List and Tuples
# Sample Database Using List and Tuples
database = []
# Main program
while True:
print("\nMenu:")
print("1. Add Record")
print("2. Display Records")
print("3. Exit")
choice = input("Enter your choice: ")
if choice == "1":
name = input("Enter name: ")
age = int(input("Enter age: "))
city = input("Enter city: ")
add_record(name, age, city)
elif choice == "2":
display_records()
elif choice == "3":
print("Exiting the program. Goodbye!")
break
else:
print("Invalid choice. Please try again.")