Question
Please provide the code solution to these problems : 1) https://www.codestepbystep.com/problem/view/python/collections/list/find_range_2d Write a function named find_range_2d that accepts a list of lists of integers as
Please provide the code solution to these problems :
1) https://www.codestepbystep.com/problem/view/python/collections/list/find_range_2d
Write a function named find_range_2d that accepts a list of lists of integers as a parameter and returns the range of values contained in the list of lists, which is equal to one more than the difference between its largest and smallest element. For example, if the largest element is 17 and the smallest is 6, the range is 12. If the largest and smallest values are the same, the range is 1. If the list is empty your function should return 0.
Constraints: You may not create any other data structures You may not modify the contents of the list.
2) https://www.codestepbystep.com/problem/view/python/collections/list/get_percent_even
Write a function named get_percent_even that accepts a list of integers as a parameter and returns the percentage of the integers in the list that are even numbers. For example, if a list a stores [6, 4, 9, 11, 5], then your function should return 40.0 representing 40% even numbers. If the list contains no even elements or is empty, return 0.0. Do not modify the list passed in.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started