+ Multiple Conditional Statements EmployeeBonus2.py >- Terminal 1 # EmployeeBonus2.py This program calculates an employee's yearly bonus File "EmployeeBonus2.py", line 22 performance rating. If the rating is 1, 2. or 3, the bonus 2 rate used is .25, .15, or .1 respectively. If the rating is 4 or elif (employeeRating >= 2): 3 # Declare and initialize variables here higher, the rate is 0. The employee bonus is calculated by 4 BONUS_1 = 0.25 SyntaxError: invalid syntax multiplying the bonus rate by the annual salary. 5 BONUS_2 = 0.15 6 BONUS_3 = 0.1 7 NO_BONUS = 0 Instructions 8 9 RATING_1 = 1 1. Variables have been declared for you, and the input 10 RATING_2 = 2 11 RATING 3 = 3 statements and output statements have been written. 12 Read them over carefully before you proceed to the 13 employeeFirstName = "Jeanne" 14 employeeLastName = "Hanson" next step. 15 employeeSalary = float("70000.00") 16 employeeRating = int("2") 17 18 # Write your code here 19 bonus = employeeRating * employeeSalary 20 if (employeeRating >=1): 2. Design the logic, and write the rest of the program using if - elif statements. 3. Execute the program entering the following as input: Jeanne Hanson bonus = RATING_1 elif (employeeRating >= 2): 21 70000.00 22 2 23 bonus = RATING_2 24 elif (employeeRating >= 3): 25 bonus = RATING_3 4. Confirm that your output matches the following: 26 # Output bonus here + employeeLas tName) 27 print("Employee Name: " + employeeFirstName + 28 print("Employee Bonus: $" + str(bonus)) 29 " " + Employee Name: Jeanne Hanson Employee Bonus: $10500 Grading
+ Multiple Conditional Statements EmployeeBonus2.py >- Terminal 1 # EmployeeBonus2.py This program calculates an employee's yearly bonus File "EmployeeBonus2.py", line 22 performance rating. If the rating is 1, 2. or 3, the bonus 2 rate used is .25, .15, or .1 respectively. If the rating is 4 or elif (employeeRating >= 2): 3 # Declare and initialize variables here higher, the rate is 0. The employee bonus is calculated by 4 BONUS_1 = 0.25 SyntaxError: invalid syntax multiplying the bonus rate by the annual salary. 5 BONUS_2 = 0.15 6 BONUS_3 = 0.1 7 NO_BONUS = 0 Instructions 8 9 RATING_1 = 1 1. Variables have been declared for you, and the input 10 RATING_2 = 2 11 RATING 3 = 3 statements and output statements have been written. 12 Read them over carefully before you proceed to the 13 employeeFirstName = "Jeanne" 14 employeeLastName = "Hanson" next step. 15 employeeSalary = float("70000.00") 16 employeeRating = int("2") 17 18 # Write your code here 19 bonus = employeeRating * employeeSalary 20 if (employeeRating >=1): 2. Design the logic, and write the rest of the program using if - elif statements. 3. Execute the program entering the following as input: Jeanne Hanson bonus = RATING_1 elif (employeeRating >= 2): 21 70000.00 22 2 23 bonus = RATING_2 24 elif (employeeRating >= 3): 25 bonus = RATING_3 4. Confirm that your output matches the following: 26 # Output bonus here + employeeLas tName) 27 print("Employee Name: " + employeeFirstName + 28 print("Employee Bonus: $" + str(bonus)) 29 " " + Employee Name: Jeanne Hanson Employee Bonus: $10500 Grading
Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
Related questions
Question
What did I do wrong. I believe I made the if statement right but I'm not sure know
![+
+
| Multiple Conditional Statements
EmployeeBonus2.py
>- Terminal
1 # EmployeeBonus2.py - This program calculates an employee's yearly bonus
performance rating. If the rating is 1, 2, or 3, the bonus
File "EmployeeBonus2.py", line 22
elif (employeeRating >= 2):
2
rate used is .25, .15, or .1 respectively. If the rating is 4 or
3 # Declare and initialize variables here
higher, the rate is 0. The employee bonus is calculated by
4 BONUS_1 = 0.25
SyntaxError: invalid syntax
multiplying the bonus rate by the annual salary.
5 BONUS_2 = 0.15
6 BONUS_3 = 0.1
7 NO_BONUS = 0
Instructions
8
9 RATING_1 = 1
1. Variables have been declared for you, and the input
10 RATING_2 = 2
statements and output statements have been written.
11 RATING_3 = 3
Read them over carefully before you proceed to the
12
13 employeeFirstName = "Jeanne"
14 employeeLastName = "Hanson"
15 employeeSalary = float("70000.00")
16 employeeRating = int("2")
next step.
2. Design the logic, and write the rest of the program
using if - elif statements.
17
3. Execute the program entering the following as input:
18 # Write your code here
'19 bonus = employeeRating * employeeSalary
20 if (employeeRating >=1):
Jeanne Hanson
21
bonus = RATING_1
70000.00
22
elif (employeeRating >= 2):
2
23
bonus = RATING_2
24
elif (employeeRating >= 3):
25
bonus = RATING_3
4. Confirm that your output matches the following:
26 # Output bonus here
27 print("Employee Name: " + employeeFirstName + " " + employeeLastName)
28 print("Employee Bonus: $" + str(bonus))
Employee Name: Jeanne Hanson
Employee Bonus: $10500
29
Grading](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F5b4afaba-eeab-4f16-8fe3-57d1f7966dfc%2Fe17d14fd-a6a3-45ba-a051-04767f7d8dde%2Fd8x8nx6_processed.png&w=3840&q=75)
Transcribed Image Text:+
+
| Multiple Conditional Statements
EmployeeBonus2.py
>- Terminal
1 # EmployeeBonus2.py - This program calculates an employee's yearly bonus
performance rating. If the rating is 1, 2, or 3, the bonus
File "EmployeeBonus2.py", line 22
elif (employeeRating >= 2):
2
rate used is .25, .15, or .1 respectively. If the rating is 4 or
3 # Declare and initialize variables here
higher, the rate is 0. The employee bonus is calculated by
4 BONUS_1 = 0.25
SyntaxError: invalid syntax
multiplying the bonus rate by the annual salary.
5 BONUS_2 = 0.15
6 BONUS_3 = 0.1
7 NO_BONUS = 0
Instructions
8
9 RATING_1 = 1
1. Variables have been declared for you, and the input
10 RATING_2 = 2
statements and output statements have been written.
11 RATING_3 = 3
Read them over carefully before you proceed to the
12
13 employeeFirstName = "Jeanne"
14 employeeLastName = "Hanson"
15 employeeSalary = float("70000.00")
16 employeeRating = int("2")
next step.
2. Design the logic, and write the rest of the program
using if - elif statements.
17
3. Execute the program entering the following as input:
18 # Write your code here
'19 bonus = employeeRating * employeeSalary
20 if (employeeRating >=1):
Jeanne Hanson
21
bonus = RATING_1
70000.00
22
elif (employeeRating >= 2):
2
23
bonus = RATING_2
24
elif (employeeRating >= 3):
25
bonus = RATING_3
4. Confirm that your output matches the following:
26 # Output bonus here
27 print("Employee Name: " + employeeFirstName + " " + employeeLastName)
28 print("Employee Bonus: $" + str(bonus))
Employee Name: Jeanne Hanson
Employee Bonus: $10500
29
Grading
Expert Solution
![](/static/compass_v2/shared-icons/check-mark.png)
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution!
Trending now
This is a popular solution!
Step by step
Solved in 2 steps
![Blurred answer](/static/compass_v2/solution-images/blurred-answer.jpg)
Recommended textbooks for you
![Computer Networking: A Top-Down Approach (7th Edi…](https://www.bartleby.com/isbn_cover_images/9780133594140/9780133594140_smallCoverImage.gif)
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
![Computer Organization and Design MIPS Edition, Fi…](https://www.bartleby.com/isbn_cover_images/9780124077263/9780124077263_smallCoverImage.gif)
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
![Network+ Guide to Networks (MindTap Course List)](https://www.bartleby.com/isbn_cover_images/9781337569330/9781337569330_smallCoverImage.gif)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
![Computer Networking: A Top-Down Approach (7th Edi…](https://www.bartleby.com/isbn_cover_images/9780133594140/9780133594140_smallCoverImage.gif)
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
![Computer Organization and Design MIPS Edition, Fi…](https://www.bartleby.com/isbn_cover_images/9780124077263/9780124077263_smallCoverImage.gif)
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
![Network+ Guide to Networks (MindTap Course List)](https://www.bartleby.com/isbn_cover_images/9781337569330/9781337569330_smallCoverImage.gif)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
![Concepts of Database Management](https://www.bartleby.com/isbn_cover_images/9781337093422/9781337093422_smallCoverImage.gif)
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
![Prelude to Programming](https://www.bartleby.com/isbn_cover_images/9780133750423/9780133750423_smallCoverImage.jpg)
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
![Sc Business Data Communications and Networking, T…](https://www.bartleby.com/isbn_cover_images/9781119368830/9781119368830_smallCoverImage.gif)
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY