write a program for a pizzeria. A pizza has a name, number of ingredients, an arrangement of
Question:
write a program for a pizzeria. A pizza has a name, number of ingredients, an arrangement of ingredients (String arrangement) and price. Create a class to represent pizza.
o The class must have a default constructor and a parameterized constructor.
o Add a method that allows keyboard entry of pizza data (all data is entered except for the price).
o Add a method that allows you to calculate the price of the pizza considering that if it has only two ingredients its price is $5.00 and for each additional ingredient its price will increase by $1.00.
o Add a method that allows you to display all the pizza data, including its calculated price.
o Create an additional class that contains the main method and test your Pizza class by creating several objects and calling their data input, calculation, and display methods.
Java An Introduction To Problem Solving And Programming
ISBN: 9780134462035
8th Edition
Authors: Walter Savitch