Selling a new vehicle pays a salesperson $1500. Selling a used vehicle pays a commission of 5% of the selling price. Write an interactive program that calculates a salesperson's total pay for selling two vehicles, each one of any type. The program should prompt the salesperson to enter the type and selling price of each vehicle. Use a loop. The program should then display the salesperson's total sales and total pay. Express these amounts in currency format as described in the requirements above.

Question

Selling a new vehicle pays a salesperson $1500. Selling a used vehicle pays a commission of 5% of the selling price. Write an interactive program that calculates a salesperson's total pay for selling two vehicles, each one of any type. The program should prompt the salesperson to enter the type and selling price of each vehicle. Use a loop. The program should then display the salesperson's total sales and total pay. Express these amounts in currency format as described in the requirements above.

Expert Answer

Want to see the step-by-step answer?

See Answer

Check out a sample Q&A here.

Want to see this answer and more?

Experts are waiting 24/7 to provide step-by-step solutions in as fast as 30 minutes!*

See Answer
*Response times vary by subject and question complexity. Median response time is 34 minutes and may be longer for new subjects.

Related Computer Engineering Q&A

Find answers to questions asked by student like you
Show more Q&A

Q: How would i solve this question? I have the sample output but how do I make it? Write a program in p...

A: Program Instructions:Create a menu using print() function and use while loop to repeatedly show the ...

Q: Consider a 4-way set associative cache made up of 64-bit words. The number of words per line is 8 an...

A: Cache size:The cache size can be calculated using the following formula:

Q: 2) Identify the errors in the following programs a) 3 errorspublic class Test {public static void ma...

A: Hey, since there are multiple questions posted, we will answer first question. If you want any speci...

Q: What are the mantissa and exponent values if 6.75 is represented in 8-bit binary floating-point repr...

A: Conversion of decimal to 8-bit floating point representation:Step 1: Convert the integer part of the...

Q: Write a program called HeadsOrTails, that lets the user guess whether the flip of a coinresults in h...

A: The following variables used:coin to hold the value of random flipcoinString to hold the text value ...

Q: Fix these codes in order to get the following output: Code: public class rinoel_Course { private Str...

A: The following is the source code which will give the same output as mentioned in the question. Also,...

Q: how do you known when you need to use int and float? I know that int refers to intergers and float r...

A: “input” keyword in Python:In Python, the function which is used to read the input from the keyboard ...

Q: What is the typical HTML5 tag which is migrate from HTML4 to HTML5? <content b. <section <fragment d...

A: HTML is a markup language that defines the properties and behavior of webpage. Since the release the...

Q: Provide a functional block diagram for a concept for an autonomous transportation and/or delivery th...

A: Autonomous transportation is the evolution of transport where the vehicles are connected to create a...