Write the pseudocode for the following scenario: A manager at a 2nd hand car dealership wants to keep track of the amount (in Rands) of commission paid to the sales people. You must take the following into consideration: • There may be more than one salesperson (each salesperson has a unique employee code)– input the employee code. An employee code of zero (0) terminates the program. • The salesperson’s commission is based on their sales (in Rands) in the past month- input the sales for each salesperson. • Calculate the total car sales (in Rands). • Calculate a salesperson’s commission (in Rands). Commission is based on the following table: Total value of cars sold Percentage commission earned Less than or equal to R500 000 10% More than R500 000 15% • Calculate the total commission the manager must pay to all of the salespeople. • Display a report for the manager in the following format: Employee Code: 2 Sales: R400000 Commission: R40000 Employee Code: 4 Sales: R650000 Commission: R97500 Total Car Sales: R1050000 Total Commission Paid: R137500
Max Function
Statistical function is of many categories. One of them is a MAX function. The MAX function returns the largest value from the list of arguments passed to it. MAX function always ignores the empty cells when performing the calculation.
Power Function
A power function is a type of single-term function. Its definition states that it is a variable containing a base value raised to a constant value acting as an exponent. This variable may also have a coefficient. For instance, the area of a circle can be given as:
Write the pseudocode for the following scenario:
A manager at a 2nd hand car dealership wants to keep track of the amount (in Rands) of commission paid to the sales people. You must take the following into consideration:
• There may be more than one salesperson (each salesperson has a unique employee code)– input the employee code. An employee code of zero (0) terminates the program.
• The salesperson’s commission is based on their sales (in Rands) in the past month- input the sales for each salesperson.
• Calculate the total car sales (in Rands).
• Calculate a salesperson’s commission (in Rands).
Commission is based on the following table:
Total value of cars sold | Percentage commission earned |
Less than or equal to R500 000 | 10% |
More than R500 000 | 15% |
• Calculate the total commission the manager must pay to all of the salespeople.
• Display a report for the manager in the following format:
Employee Code: 2
Sales: R400000
Commission: R40000
Employee Code: 4
Sales: R650000
Commission: R97500
Total Car Sales: R1050000
Total Commission Paid: R137500
Trending now
This is a popular solution!
Step by step
Solved in 2 steps