This programming project extends Programming Project 4.11. Create a Pizza- Order class that allows up to three pizzas to be saved in an order. Each pizza saved should be a Pizza object as described in Programming Project 4.11. In addition to appropriate instance variables and constructors, add the following methods:
•public void set Num Pizzas (int num Pizzas)—sets the number of pizzas in the order. num Pizzas must be between 1 and 3.
• Public void setpizzal(pizza pizza1)— sets the first pizza in the order.
• Public void setpizza (pizza pizza2)— sets the second pizza in the order.
• Public void setpizza (pizza pizza3)— sets the third pizza in the order.
•Public double calctatal()—Returns the total cost of order.
Write a main method to test the class. The set pizza2 and setpizza3 method only will be used if there are two or three pizza in the order, repectively. Sample code illustrating the method is shown below. Note that first three lines are incomplete. You must complete them as part of the programming project.
We need at least 10 more requests to produce the solution.
0 / 10 have requested this problem solution
The more requests, the faster the answer.