top of page
Writer's pictureRajesh Singh

Python program to find minimum value in List


Program:

list=[(1,15,11), (4,7,1), (7,11,2),(10,10,18)]

print("The list is: " +str(list))

res1=min(list)[0]

res2=min(list)[1]

res3=min(list)[2]

print("The min of index 1: " +str(res1))

print("The min of index 2: " +str(res2))

print("The min of index 3: " +str(res3))


Output:

The list is: [(1, 15, 11), (4, 7, 1), (7, 11, 2), (10, 10, 18)]

The min of index 1: 1

The min of index 2: 15

The min of index 3: 11



47 views0 comments

Recent Posts

See All

Comments


bottom of page