Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

java language P2 (Banical Problem Solving Lab/ Tip and Total Payment saved 4. Tip and Total Payment 20 points possible Roset to Starter Code Write

java language
image text in transcribed
image text in transcribed
P2 (Banical Problem Solving Lab/ Tip and Total Payment saved 4. Tip and Total Payment 20 points possible Roset to Starter Code Write a program that calculates the tip and total amount of payment after a meal in a restaurant. For example, if the subtotal is $10 and the tip rate is 15% (note that the user enters is instead of 0.15 for 15%), the program should display S15 for tio an $115 for the total. The following is a sample run Note that you will need to use print to print exactly two decimal places after the period for both the tip and the total payment. > run TipCalculator Enter the subtotal and a tip rate: The tip is $1.50 and total is $11.50 10 15 I Exercise 4: Convert the change in total cents into dollar bills, quarters, dimes, nickels and pennies. Step 1: Problem Analysis (Please add rows if necessary) Description Variable name Inputs to the program Outputs of the program Step 2: Algorithm (Plan of the Program). Fill the blanks with variable names you decided to use in Step 1. 10. Prompt the user to enter value(s) for 11. Compute value(s) for 12. Display Step 3: Code (You will do the coding part later for another assignment. You'll submit your code in an assignment in class.mimir.lo and another D2L assignment. Please don't copy your code below.) P2 (Banical Problem Solving Lab/ Tip and Total Payment saved 4. Tip and Total Payment 20 points possible Roset to Starter Code Write a program that calculates the tip and total amount of payment after a meal in a restaurant. For example, if the subtotal is $10 and the tip rate is 15% (note that the user enters is instead of 0.15 for 15%), the program should display S15 for tio an $115 for the total. The following is a sample run Note that you will need to use print to print exactly two decimal places after the period for both the tip and the total payment. > run TipCalculator Enter the subtotal and a tip rate: The tip is $1.50 and total is $11.50 10 15 I Exercise 4: Convert the change in total cents into dollar bills, quarters, dimes, nickels and pennies. Step 1: Problem Analysis (Please add rows if necessary) Description Variable name Inputs to the program Outputs of the program Step 2: Algorithm (Plan of the Program). Fill the blanks with variable names you decided to use in Step 1. 10. Prompt the user to enter value(s) for 11. Compute value(s) for 12. Display Step 3: Code (You will do the coding part later for another assignment. You'll submit your code in an assignment in class.mimir.lo and another D2L assignment. Please don't copy your code below.)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Repairing And Querying Databases Under Aggregate Constraints

Authors: Sergio Flesca ,Filippo Furfaro ,Francesco Parisi

2011th Edition

146141640X, 978-1461416401

More Books

Students also viewed these Databases questions