Python Quiz 3 - "Using For Loop to see List's value is 'Numeric' and greater than '6' "
Python Quiz 3 -
"Using For Loop to see List's value is 'Numeric' and greater than '6' "
CODE
list1 = ["s", "a", "b" , "k", 2, 3, 8, 7, 10, 458, -1, -100, 6, 6.56, 6.000001]
for items in list1:
if str(items).isnumeric() and items>6:
print(items)
"""Output ---
8
7
10
458
"""
Comments
Post a Comment