Answered step by step
Verified Expert Solution
Question
1 Approved Answer
A sales company implemented a new incentive scheme for their frontline salesman. The incentive scheme is described as below: The amount of incentive for
A sales company implemented a new incentive scheme for their frontline salesman. The incentive scheme is described as below: The amount of incentive for first quarter (Q1) and a medal would be granted to the salesman is based on the revenue in Q1 defined as follows, Revenue (in Million) in Q1 Above or equal to $1000 Below $1000 and above or equal to $500 Below $500 Medal in Q1 Gold For example, if the revenue in Q1 of a salesman is $800M, the total amount of incentive is calculated by, Incentive Q1 = Revenue in Q1 x Incentive rate= $800M x 5% = $40M and a "Silver" medal would be granted to the salesman. The amount of incentive for second quarter (Q2) is based on the Medal granted in Q1 and the revenue in Q2 defined as follows, Silver Incentive rate 10% 5% 2% Brown Revenue (in Million) in Q2 Medal Gold Silver Brown Above or equal to $2000 Below $2000 Above or equal to $2000 Below $2000 Above or equal to $2000 Below $2000 Incentive rate 20% 18% 15% 8% 5% 3% For example, if the medal granted in Q1 of a salesman is "Silver" and the revenue in Q2 is $2200M, the total amount of incentive is calculated by, Incentive Q2 = Revenue in Q2 x Incentive rate = $2200M X 15% = $330M A program is required to calculate and report the incentive for each salesman in BOTH Q1 and Q2. Write a Python program to perform the following tasks: (a) [4 pts] Ask the salesman (user) to input the revenues (integer values) for Q1 and Q2 separately. An exception handling scheme should be included to avoid any run-time errors for any invalid input value during execution. Solution. (b) [4 pts] Calculate and report the amount of incentive and medal granted for the salesman in Q1 based on the inputs from (a). Solution. (c) [7 pts] Calculate and report the amount of incentive salesman in Q2 based on the inputs from (a) and the medal granted in Q1. The sample outputs are shown below: Solution. Case 1: Enter the revenue in Q1 (integer in $M) :icp INVALID INPUT! is NOT an integer Case 2: Enter the revenue in Q1 (integer in $M) :2000 Enter the revenue in Q2 (integer in $M) :icp INVALID INPUT! is NOT an integer Case 3: Enter the revenue in Q1 (integer in $M) :800 Enter the revenue in Q2 (integer in $M) :1000 The amount of incentive in Q1 is $40.0M and Silver Modal is granted! The amount of incentive in Q2 is $80.0M
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started