Question: python only. 11. Write the Python program specified here: This purpose of this program is to compute the amount of a tip to leave at

 python only. 11. Write the Python program specified here: This purpose

python only.

11. Write the Python program specified here: This purpose of this program is to compute the amount of a tip to leave at a restaurant after a meal. The program asks the user for the amount on the bill and the number of diners at the table. If the number of diners is six or more, the default tip percentage will be 18%. If the number of diners is less than six, the program will ask the user for the desired tip percentage. The program then prints the original amount of the bill, the calculated tip amount, and the total amount. You may assume that all user inputs are valid. You do not have to worry about printing only two digits after a decimal point. You do not have to comment your program contained within one or more function definitions. The main function is to be called whatToPay () and works like this: All vour code must be >>> whatToPay() Enter the amount on your bill: 57.50 Enter the number of diners: 4 Enter the desired tip percentage: 15 bill is $ 57.5 tip is 8.625 Your Your Your total due is $ 66.125 >>> whatToPay() Enter the amount on your bill: 100 Enter the number of diners: 6 Your bill is $ 100.0 Your tip is $ 18.0 Your total due is $ 118.0

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!