Question: Calculate the Bill, including a Tip & Tax Write a static method called calculateCost ( ) , with 4 parameters of type int, and returning
Calculate the Bill, including a Tip & Tax
Write a static method called calculateCost with parameters of type int, and returning a String as specified below.
You method should calculate the total cost of ordering different meals. The number of meals of each type will be input by the console and given to your method. Your method should add the cost of each type of meal, calculate the Meal Tax, calculate the Tip, and print the total cost.
Meal costs:
Meal Steak Dinner:
Meal Steak & Lobster Dinner:
Meal Vegetarian Extravaganza:
Meal Chicken Dinner:
Input looks like: mealCount mealCount mealCount mealCount
Meal Tax is: multiply mealTotal by and add it to the taxTotal
Standard Tip is: multiply mealTotal by and store in tipTotal
Output should look like: "The total cost for this meal is $ n where n is the cumulative total of the meal, the tax & the tip. in java
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
