Question: python' You are writing a game and need a function to calculate what a character's experience points will increase by after a battle. For entering

python' You are writing a game and need a function to calculate what a character's "experience points" will increase by after a battle. For entering the battle, the character earns a minimum of 21275 "experience points", but they will earn even more if they win the battle. Write a function named "compute_xp" that takes two parameters representing the additional experience points earned for winning the battle (an integer) and if the character won the battle (a boolean), in that order. The function will return 21275 if the boolean is false (they lost the battle) or 21275 plus the integer parameter if the boolean is true (they won the battle) 1 |
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
