0
print(min(1, 2, 3, 4, 0, 2, 1)) print(max([1, 4, 9, 2, 5, 6, 8])) print(abs(-99)) print(abs(42)) print(sum([1, 2, 3, 4, 5]))
print(sum([1,2,3,4,5])) ,why sum enclosed in brace??
4 Antworten
+ 2
Sum only takes an iterable, max for example can take an iterable or individual elements/arguments.
+ 1
The count of parentheses between min and sum are the same.
+ 1
" Sum() " is a function .
And you have to find sum of list of numbers , so you give list of numbers in sum function