ENع
الدرس 20 · Algorithms

Recursion

لم يُترجم بعد؛ يُعرض باللغة الإنجليزية

A recursive function solves a problem by calling itself on a smaller copy of the same problem, until it reaches a case small enough to answer straight away. Follow fact(4) as Python stacks up one call frame per waiting call, hits the base case, then unwinds with return values. Then see Python's depth limit, the loop alternative, and why naive Fibonacci repeats work.

10 دقيقة12 خطوات5 أسئلةIntermediate
شكل 20 · تفاعلي
جارٍ تحميل الرسم…
أو ← →

اختبار يتاح بعد الخطوة الأخيرة.