l = [ ]
num = int(input(“Enter num of element”))
for i in range (1, num+1):
ele = int(input(“Enter elements”)
l.append(ele)
print(“Smallest element is:” , min(l))
3 Likes
Good, Keep it up… try it using loop also.
There are various way to solve this problem .
1.) using min which you have done.
2.) you can sort the list and print the first element
1 Like