Question
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.
0 0
Add a comment Improve this question Transcribed image text
Answer #1

CODE:tipper.py

print("Bill Tipper program.")

bill_Total = int(input("\n What's your bill?" \

" Please round up the nearest pound . "))

Tip_fifteen = int((bill_Total / 100 )* 15)

Tip_twenty = int((bill_Total / 100) * 20)

print("\nIf your bill total is £",bill_Total,", a 15% tip would be £" \

,Tip_fifteen,"\n so total bill with tip is £",bill_Total + Tip_fifteen)

print("\nIf you're feeling generous then a 20% tip would be £" \

,Tip_twenty,"\n so total bill with tip is £",bill_Total + Tip_twenty)

input("\n\nPress Enter to exit.")

Add a comment
Know the answer?
Add Answer to:
Use Python programming #3 on page 47 of your python programming book: Write a Tipper program...
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
  • 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...

  • 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...

  • 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

  • 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 programming)) 2. In this exercise you will create a program that reads a letter of...

    ((python programming)) 2. In this exercise you will create a program that reads a letter of the alphabet from the user. If the user enters a, e, i, o or u then your program should display a message indicating that the entered letter is a vowel. If the user enters y then your program should display a message indicating that sometimes y is a vowel and sometimes y is a consonant. Otherwise your program should display a message indicating that...

  • Python Programming 4th Edition: Write a program that asks the user for the number of feet....

    Python Programming 4th Edition: Write a program that asks the user for the number of feet. The program converts those feet to inches by using the formula ’12 * feet’. Hint: Define main () program Get the number of feet from the user Define variables Call a function feet_to_inches(feet) The function receives the number of feet and returns the number of inches in that many feet. The output should look like as follows: Enter the number of feet: If the...

  • Please write comments with the program. Python programming!! Part III - write student data In this...

    Please write comments with the program. Python programming!! Part III - write student data In this part the program should create a .csv file and fill it with generated student information. The program should: Ask the user for a name for the .csv file (use your own name for the exercise) Create the .csv file with columns named - ID, first-name, GPA Based on the information received in part I, generate and fill students information in the CSV file Tell...

  • write a c programming Write a program that will calculate the perimeter, area and volume of...

    write a c programming Write a program that will calculate the perimeter, area and volume of a is is entered by the user. Your program will display the radius, perimeter, area and volume to the monitor and will also save them to a file called "circlePAV.txt". Your program should prompt the user for the radius until the user enters -1. Use the following structure. typedef struct ( float radius; float area, float perimeter; float volume; ylinder Figure>

  • Write a Python program which prompts the user for a file name then a sentence. Display...

    Write a Python program which prompts the user for a file name then a sentence. Display the number of characters in the sentence and save the sentence to the file name. If the file already exists, ask the user if the file should be overwritten.

  • (PYTHON) Write a program that displays the following menu:. , Write Algorithm for Code Geometry Calculator...

    (PYTHON) Write a program that displays the following menu:. , Write Algorithm for Code Geometry Calculator 1. Calculate the Area of a Circle 2. Calculate the Area of a Rectangle 3. Calculate the Area of a Triangle 4. Quit Enter your choice (1 - 4): If the user enters 1, the program should ask for the radius of the circle and then display its area. If the user enters 2, the program should ask for the length and width of...

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