Smallest and Largest Number in a List

Python Tutorial to get smallest and largest number in a list.
list1 = [20, 50, 57, 100, 45, 67]
print(list1[0],"= Smallest")
print(list1[-1],"= largest")
20 = Smallest
100 = largest
Default image
Aman Kharwal

I am a programmer from India, and I am here to guide you with Data Science, Machine Learning, Python, and C++ for free. I hope you will learn a lot in your journey towards Coding, Machine Learning and Artificial Intelligence with me.

Leave a Reply

Data Science | Machine Learning | Python | C++ | Coding | Programming | JavaScript