Elle Joy Vasquez
Preliminary Test 04
Create a Python function that takes a list of n integers and returns the largest number among the n integers.
def int_max(lst):
return max(lst)
x = [1, 34, 45, 56, 65, 43, 23, 33]
print(f'in list {x}, max = {int_max(x)}')
OUTPUT:
in list [1, 34, 45, 56, 65, 43, 23, 33], max = 65
Comments
Leave a comment