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 ▸

Write a simple Python program that asks a user to input their age and name and then return the text: "Hi my name is *NAME*, and I am *AGE* years old."


Print "Hello World!" ten times without typing (or pasting) the print function more than once


How do For Loops work?


Write a function that takes a list of numbers as input, and outputs the average of the numbers. The function should catch any errors.