In this problem, you should write one function named sum_nums
.
This function should have one parameter, which you can assume will be a 2 dimensional list of numbers.
The function should iterate through all of the numbers, and sum all of the ones whose value is less than 10.
The function should return the sum.
For instance, the code:
data = [[2, 12, 2], [12, 5, 100, 9]]
numbers = sum_nums(data)
print(numbers)
Should print
18
Make sure to include only the one function in your file.
The gradescope tests will call the functions to test them.
Name the program prep32.py
.
Make sure that gradescope gives you the points for passing the test case.