Challenge: Adjusting Salary with a Bonus
Uppgift
Swipe to start coding
Your company has decided to reward employees with a performance bonus of 250%. You need to update the salary calculator to include this bonus in the final salary calculation.
Extend the program by doing the following:
- Declare a new constant called
bonuswith a value of2.5. - Before showing the output, multiply the value of
totalPaywithbonusand store the result back intotalPay. (Use the shorter syntax for this arithmetic operation).
Lösning
Var allt tydligt?
Tack för dina kommentarer!
Avsnitt 1. Kapitel 24
single
Fråga AI
Fråga AI
Fråga vad du vill eller prova någon av de föreslagna frågorna för att starta vårt samtal
Fantastiskt!
Completion betyg förbättrat till 1.33
Challenge: Adjusting Salary with a Bonus
Svep för att visa menyn
Uppgift
Swipe to start coding
Your company has decided to reward employees with a performance bonus of 250%. You need to update the salary calculator to include this bonus in the final salary calculation.
Extend the program by doing the following:
- Declare a new constant called
bonuswith a value of2.5. - Before showing the output, multiply the value of
totalPaywithbonusand store the result back intotalPay. (Use the shorter syntax for this arithmetic operation).
Lösning
Var allt tydligt?
Tack för dina kommentarer!
Avsnitt 1. Kapitel 24
single