Python Practice › List Programs › Program 26
max, min and sum
Write a Python program to get the maximum, minimum and sum of a list with built-in functions.
Input
[8, 3, 15, 6]
Output
15 3 32
Approach
max(),min(),sum().
Solution
numbers = [8, 3, 15, 6]print(max(numbers), min(numbers), sum(numbers))Output
15 3 32
Learn the concept
New to this topic? Read the lesson, then come back.