Question: Please help; using python wing 101 : Use the function design recipe to develop a function named big_diff. The function has one parameter, which is
Please help; using python wing 101 :
Use the function design recipe to develop a function named big_diff. The function has one parameter, which is a list of integers. Assume that the list has at least two integers. The function returns the difference between the largest and smallest elements in the list. For example, when the function's argument is [10, 3, 5, 6], the function returns 7. Your function definition must have type annotations and a complete docstring. Although the most Pythonesque solution is: def big_diff(nums): return max(nums) - min(nums) don't use this as your solution. Your function is not permitted to call Python's min and max functions. Your function must have exactly one loop. Use the Python shell to test big_diff.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
