الرجوع
تسجيل الدخول
أنت تتصفح نسخة مؤرشفة من الموقع اضغط للانتقال إلى الموقع الجديد بكامل المزايا

What is the error in the following code snippet if the intention is to find the largest value?

largest_so_far = -1
for the_num in [9, 41, 12, 3, 74, 15]:
    if the_num < largest_so_far:  # Error here
        largest_so_far = the_num