BasicsChallenge 4 of 34

Largest, by hand

Write largest(numbers) that returns the biggest number in a non-empty — without using the built-in max() or sorted().

Examples
largest([3, 9, 2, 7]) → 9
Exercise

Largest, by hand

3 checks
def largest(numbers):
    ...


print(largest([3, 9, 2, 7]))
 
Python (loads on first run)Ctrl+Enter runs
Output
Press Run to try your code, then Check answer to grade it.