Question: Create a new editor window and save it as a file named lab5ex4.py. Step 2: You've volunteered to repaint the walls in Leo's Lounge and
Create a new editor window and save it as a file named lab5ex4.py. Step 2: You've volunteered to repaint the walls in Leo's Lounge and will need to use a ladder when painting close to the ceiling. You know that a ladder has to be placed against a wall at an angle; otherwise, it will fall over. Use the function design recipe to design, code and test the definition of a function named height. This function takes the length of a ladder, measured in metres, and the angle that it forms with the ground as it leans against the wall, measured in degrees. It returns the height reached by the ladder. Your function definition: must have type annotations and a complete docstring. Think carefully about the range of permitted values for the two parameters. Remember to document these in your docstring must have exactly one statement in the function body: return followed by an expression. Do not use local variables.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
