Manually implement a function that finds the smallest value in a list of integers and print it.

def findMin(list): min = list[0] for i in range(1, len(list)): if list[i] < min: min = list[i] print(min)

DH

Related Python Mentoring answers

All answers ▸

What is the difference between a list and an array?


Write a recursive function that takes any integer n and prints the nth Fibonacci number.


How do I check if a number is prime using a python program?


How can you take a list of numbers and add 3 to every number in the list using only one line of code?