Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Write a function in Python, called PrintThem(ls) that takes a list variable ls as argument. It then prints out the sum, the maximum, and the
Write a function in Python, called PrintThem(ls) that takes a list variable ls as argument. It then prints out the sum, the maximum, and the minimum of all elements in the list, each on separate lines and each with an announcement, like this sample run below. The function prints these things without returning any value. You can safely assume that the variable ls will always just include integer numbers (you dont have to check for that).
>>> x = [5, 2, 10, 7]
>>> PrintThem(x)
The sum is: 24
The max is: 10
The min is: 2
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