--- Python3 ---
import random
lst = [random.randint(1,100) for i in range(50)]
print(*lst)
try:
print( max( filter(lambda p: p % 2 == 0, lst) ) )
except:
print('List has no Even numbers')
Объяснение:
--- Python3 ---
import random
lst = [random.randint(1,100) for i in range(50)]
print(*lst)
try:
print( max( filter(lambda p: p % 2 == 0, lst) ) )
except:
print('List has no Even numbers')
Объяснение: