Question: For this assignment, we ll create a simple bill calculator, similar to what s used in restaurants to determine the total amount to charge a
For this assignment, well create a simple bill calculator, similar to whats used in restaurants to
determine the total amount to charge a customer that adds tax and a tip to the subtotal. Use the
following requirements to complete the application:
Ask the user for the subtotal amount.
Ask the user for the tip percent, showing the value including the tax.
Calculate the total and print a breakdown to the user.
a Use a constant value of for the sales tax to calculate the tax.
b Add the tax to the subtotal.
c Calculate the tip amount by multiplying the tip percent by the amount in part b
d Display the cost breakdown as shown below.
Example Program
Enter the subtotal amount:
Enter the tip percent for $:
Subtotal: $
Tax : $
$
Tip : $
Total: $Ask the user for a subtotal amount
Console.WriteLineplease enter the subtotal amount:";
double subtotal double.ParseConsoleReadLine;
double subtotalWithTax subtotal subtotal TAX ;
Ask the user for the tip percent, showing the value including the tax.
Console.WriteLine$"please enter a tip percent for subtotalwithTax:C;
double tip double.ParseConsoleReadLine;
Calculate the total and print a breakdown to the user.
Console.WriteLine$subtotalsubtotalWithTaxtip Tip Amount: tip subtotalwithTax:C;
Enter the subtotal amount:
Enter the tip percent for $:
Subtotal:
$
Tax : $
$
Tip : $
Total: $
I am stuck in the provided picture
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
