Question 14: List

School Supply Shopping

The new school term is starting, and you’re at the School Supply Store to pick up all the essentials you’ll need for the year. With a variety of items to choose from, you must decide what to buy and keep track of everything in your shopping list.

Instructions:
  1. Start with an empty shopping list:

    • Use the list supply_list to store the names of the items you choose to purchase.
  2. Choose items to buy:

    • The program will ask you for each item if you want to buy it:
      Press 1 to buy [item] or 2 to not.
    • Available items include:
      • Notebooks
      • Pencils
      • Backpack
      • Erasers
      • Water Bottle
  3. Check your shopping summary:

    • At the end of your shopping, the program will display:
      • The total number of items purchased.
      • The list of items you bought.
Write what you are looking for, and press enter to begin your search!