Question

Write a C  program that computes the tax and tip on a restaurant bill for a patron...

Write a C  program that computes the tax and tip on a restaurant bill for a patron with a $88.67 meal charge. The tax should be 6.75 percent of the meal cost. The tip should be 20 percent of the total after adding the tax. Display the meal cost, tax amount, tip amount, and total bill on the screen.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

1 #include<stdio.h> 2 3 int main() 5 float mealcost 88.67;//Cost of meal for a patron 6| float tax = 6.75 * me alcost / 100;/

OUTPUT:
CAUsers Shubham Desktop Untitled1.exe Meal cost: $88.67 Tax amount: $5.99 Tip amount: $18.93 Total bill: $113.59 Process exit

Add a comment
Know the answer?
Add Answer to:
Write a C  program that computes the tax and tip on a restaurant bill for a patron...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Bill and Tip Calculator Write a C program to generate a receipt for a restaurant. Your...

    Bill and Tip Calculator Write a C program to generate a receipt for a restaurant. Your application should allow the user to enter the bill amount and allow them to decide if they would like to leave a 15 percent tip or not. ▪ Do not allow the user to enter a negative value for the bill. ▪ Display the bill amount, tax amount, tip amount, and total amount. ▪ To calculate the tip, multiply the bill amount by 0.15....

  • Python Simple Programming Write a program in Python that calculates the tip and total for a...

    Python Simple Programming Write a program in Python that calculates the tip and total for a meal at a restaurant. When your program is run it should ... Calculate the tip and total for a meal for a restaurant Print the name of the application "Tip Calculator" Get input from the user for cost of meal and tip percent Print the tip and total amounts. The formula for calculating the tip amount is: tip = cost of meal * (tip...

  • in C# Write an object-oriented program that can be used to determine the tip amount that...

    in C# Write an object-oriented program that can be used to determine the tip amount that should be added to a restaurant charge. Allow the user to input the total, before the taxes (9% of the total) and the tip charge of 15%. Produce output showing the calculated total amount due. Tax should be added to the bill before the tip is determined. i will rate if correct

  • Language - PYTHON Design a program that calculates the total amount of a meal purchased at a restaurant

    Language - PYTHONDesign a program that calculates the total amount of a meal purchased at a restaurant. The program should ask the user to enter the charge for the food, and then calculate the amount of a 15% tip and 7% sales tax. Display each of these amounts and the total.Please help, I have no idea where to begin. Thanks

  • write a java code to calculate a restaurant tip based on the diner’s satisfaction on a...

    write a java code to calculate a restaurant tip based on the diner’s satisfaction on a scale of 1 – 5. The user will input the total bill and their rating. The program should output the tip percentage, tip amount, and total due. You must use a select statement instead of an if. For a rating of 1, calculate a 10 % tip. For a rating of 2, calculate a 12.5% tip. For a rating of 3, calculate a 15...

  • Python 3. Can anyone please help me with these two homework using Python 3. Thanks in...

    Python 3. Can anyone please help me with these two homework using Python 3. Thanks in advance 8. Tip, Tax, and Total Write a program that calculates the total amount of a meal purchased at a restaurant. The program should ask the user to enter the charge for the food, and then calculate the amount of a 15 percent tip and 7 percent sales tax. Display each of these amounts and the total. 9. Celsius to Fahrenheit Temperature Converter Write...

  • Write a program that asks the user to enter the types of dark chocolate and the...

    Write a program that asks the user to enter the types of dark chocolate and the number of packages purchased at the SHSU@ACM freshly made store. Make sure that you display the following chart for the user to make the selection. The plain base chocolate cost $5.00. The flavor and sweetness can be added to add on various rate. Chocolate Intensity Percentage                   Flavor & Sweetness              Cost Rate             1 - 25%                                               Super Sweet                            10% 26 - 50%        ...

  • C++ Write a pseudocode algorithm for a program that reads the subtotal and the tip rate,...

    C++ Write a pseudocode algorithm for a program that reads the subtotal and the tip rate, then computes the tip and total.

  • Use Python programming #3 on page 47 of your python programming book: Write a Tipper program...

    Use Python programming #3 on page 47 of your python programming book: Write a Tipper program where the user enters a restaurant bill total. The program should then display two amounts: a 15% tip and a 20% tip. Name your file tipper.py Previous Next.

  • need help in this java program static void main(String[] args) /* Assume that you and a...

    need help in this java program static void main(String[] args) /* Assume that you and a few of your friends went to a restaurant, ** Assume You want to split the bill equally after having the meal. Write a code that will take the bill amount, tax percentage, tip, and the number of people as inputs and prints the share amount in dollars each person has to pay. Assume that the tax is 8.5 %, and the tip 1s 15...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT