Develop a console program that simulates the preparation of pizzas, for it requires the following ingredients: Chile, Onion, Cheese, Pasta, Pineapple, Coconut, Tomato Sauce, Olives, Ham, Peperoni and Ground Beef, each ingredient has the particularity of being considered sweet or salty and a quantity of calories (must handle these attributes in a class called "Ingredient".

Currently the menu contains 4 types of pizza:

Type Ingredients
Supreme Chile, Onion, Cheese, Fungi, Pepperoni
Ham Ham cheese
Hawaiian Ham, Cheese, Pineapple and Coconut
Pepperoni Pepperoni, Cheese

All the pizzas contain Pasta and Tomato Sauce.

Use an array to handle the inventory of ingredients where each position is an ingredient, each position must contain the following quantities: see image.

The program should contain the following options:

1."Request pizza": It will allow the client to order the pizza he wants so that the customer can choose only one type of pizza at a time, the program will validate if he has enough ingredients to make it, if not enough will show a message That says "It is not possible to dispatch your pizza due to lack of ingredients, excuse the inconvenience" and will return to the previous menu, every time a pizza is ordered the customer will be asked to add olives. When registering an order this must be added in an array of objects of type "Pizza" (which contains an arrangement of type "Ingredient" of 10 positions) because the pizzeria sells 40 pizzas a day this arrangement should have that size.

2."Show Ingredient Inventory": You should print on screen the amount of each ingredient in the inventory.

3."Restart quantity in inventory": You must restart the inventory of ingredients inventory.

4."Show pizzas sold": Will display the pizzas sold in the order they were sold.

5."Exit": The program ends

Academic Honesty!
It is not our intention to break the school's academic policy. Posted solutions are meant to be used as a reference and should not be submitted as is. We are not held liable for any misuse of the solutions. Please see the frequently asked questions page for further questions and inquiries.
Kindly complete the form. Please provide a valid email address and we will get back to you within 24 hours. Payment is through PayPal, Buy me a Coffee or Cryptocurrency. We are a nonprofit organization however we need funds to keep this organization operating and to be able to complete our research and development projects.