December 2001
Beginner
976 pages
22h 4m
English
![]() | Applying It |
Try to complete the following exercise by yourself.
Create a class that models a pizza ordering system. You must have a class for the pizza order. The class must specify the name of the caller (the person who ordered the pizza), the size of the pizza (small or large), and the ingredients (pepperoni, sausage, cheese, and so on). Each ingredient has a fixed price based on the size of the pizza ($1.00 for small and $2.00 for large). The base price for a pizza with no ingredients (sauce and cheese only) is $6.00 for a small and $10.00 for a large.
Your class must have methods to change the size, add ingredients, and ...
Read now
Unlock full access