Duplicate Question
The question on this page has been marked as a duplicate question.
Original Question
A small startup software developer company needs to create a program that will calculate the pay of its employees. For the firs...Asked by jesse
A small startup software developer company needs to create a program that will calculate the pay of its employees. For the third version of the program, the company wants the program to accept an employee’s name, the number of hours the employee worked, and the hourly pay rate. The program will then calculate the gross pay, display the employee’s name, number of hours worked, pay rate, and gross pay, but also calculate and display the net pay of the person after taxes have been calculated and deducted. The user will then be able to continue calculating the pay for additional employees until the user decides to stop or until the maximum number of employees is reached.
Can you show me how to make a loop for this problem??
Can you show me how to make a loop for this problem??
Answers
Answered by
MathMate
Do you programme in Java, C++ or VB, or do you need to do only the UML or pseudocode?
Basically, loops will repeat itself until a defined number of times is reached, or when the program decides to interrupt the loop. In Java and C++, the interruption is by the statement "break", and in VB, it is exit.
So the number of employee is normally known in advance, so can be used to define the number of repetitions of the loop. If the user decides to stop (for lunch or otherwise), he can enter a special value to indicate to the programme that an exit (or break) from the loop is requested.
If you have actual code, it is easier to describe or correct.
Basically, loops will repeat itself until a defined number of times is reached, or when the program decides to interrupt the loop. In Java and C++, the interruption is by the statement "break", and in VB, it is exit.
So the number of employee is normally known in advance, so can be used to define the number of repetitions of the loop. If the user decides to stop (for lunch or otherwise), he can enter a special value to indicate to the programme that an exit (or break) from the loop is requested.
If you have actual code, it is easier to describe or correct.
Answered by
Fran
A software company sells a package that retails for $99. Quantity discounts are given according to the following table. Quantity Discount
10-19 20%
20-49 30%
50-99 40%
100 or more 50%
Write a program that asks for a number of units purchased and computes the total cost of the purchase.
10-19 20%
20-49 30%
50-99 40%
100 or more 50%
Write a program that asks for a number of units purchased and computes the total cost of the purchase.
Answered by
Fran
Need an answer for this program for the software company. Can someone give me an answer.
There are no AI answers yet. The ability to request AI answers is coming soon!
Submit Your Answer
We prioritize human answers over AI answers.
If you are human, and you can answer this question, please submit your answer.