Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a java method calc_pizza_charge() that takes four integer arguments, one for the size (1 small, 2 medium, 3 large), one for the number of

image text in transcribed
Write a java method calc_pizza_charge() that takes four integer arguments, one for the size (1 small, 2 medium, 3 large), one for the number of meat toppings, one for the number of other toppings and another for the quantity of pizzas ordered. It should calculate and return the total due for that pizza order based on the following information: Small pizza base price: $6.50 Medium pizza base price: $9.50 Large pizza base price: $11.50 The base pizza price includes one meat and one non-meat topping. Additional meat toppings are charged at $3.50 each. Additional non-meat toppings are charged at $1.5 each. Sample Run: Enter pizza size (1 small, 2 medium, 3 large): 3 Enter number meat toppings: 2 Enter number or non-meat toppings: 3 Enter number of pizzas ordered: 2 Pizza Total: $36.00

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle Autonomous Database In Enterprise Architecture

Authors: Bal Mukund Sharma, Krishnakumar KM, Rashmi Panda

1st Edition

1801072248, 978-1801072243

More Books

Students also viewed these Databases questions