Question
                The program below asks the user to enter several integers, which are added to a list called values. Use the core math functions to find and display the minimum and maximum values and the sum of all entered values.
Use min() to find the minimum value. Print that minimum to the screen with the message "Min = [value]"
Use max() to find the maximum value. Print that maximum to the screen with the message "Max = [value]"
Use sum() to find the sum of all values. Print that sum to the screen with the message "Sum = [value]"
The following examples demonstrate the expected program output.
Enter list value: 2
Enter list value: 1
Enter list value: 3
Min = 1
Max = 3
Sum = 6
Enter list value: -10
Enter list value: 200
Enter list value: 30
Min = -10
Max = 200
Sum = 220
            
            
        Use min() to find the minimum value. Print that minimum to the screen with the message "Min = [value]"
Use max() to find the maximum value. Print that maximum to the screen with the message "Max = [value]"
Use sum() to find the sum of all values. Print that sum to the screen with the message "Sum = [value]"
The following examples demonstrate the expected program output.
Enter list value: 2
Enter list value: 1
Enter list value: 3
Min = 1
Max = 3
Sum = 6
Enter list value: -10
Enter list value: 200
Enter list value: 30
Min = -10
Max = 200
Sum = 220
Answers
                    Answer
            
    import math
values = []
for i in range(0,3):
value = int(input("Enter list value: "))
values.append(value)
    
values = []
for i in range(0,3):
value = int(input("Enter list value: "))
values.append(value)
                    Answered by
            GPT 3.5
            
    # Program to find minimum, maximum, and sum of entered values
values = []
while True:
try:
value = int(input("Enter list value: "))
values.append(value)
except ValueError:
break
if values:
minimum = min(values)
maximum = max(values)
total = sum(values)
    
print(f"Min = {minimum}")
print(f"Max = {maximum}")
print(f"Sum = {total}")
else:
print("No values entered.")
    
values = []
while True:
try:
value = int(input("Enter list value: "))
values.append(value)
except ValueError:
break
if values:
minimum = min(values)
maximum = max(values)
total = sum(values)
print(f"Min = {minimum}")
print(f"Max = {maximum}")
print(f"Sum = {total}")
else:
print("No values entered.")
                    Answered by
            GPT 3.5
            
    import math
values = []
for i in range(3):
value = int(input("Enter list value: "))
values.append(value)
    
values = []
for i in range(3):
value = int(input("Enter list value: "))
values.append(value)
Submit Your Answer
We prioritize human answers over AI answers.
If you are human, and you can answer this question, please submit your answer.