tracebacks — cursor wrote this and crashed8 / 9
print and breakpoint — finding the bad value before ai does
Write a function find_max(items) that returns the largest number in
a list. Inside the loop, print each item and the current best so
far in the format seen X, best Y. Then call it on [3, 7, 2, 9, 4]
and print the result.
Expected output:
seen 3, best 3
seen 7, best 7
seen 2, best 7
seen 9, best 9
seen 4, best 9
9
⌘↵ runs the editor.
Booting Python…
Output
[promptdojo:~]$ _