Skip to content · ⁨الانتقال إلى المحتوى⁩

Array algorithms: max, count, search, average · ⁨خوارزميات المصفوفات: الحد الأقصى، العد، البحث، المتوسط⁩

Four classic array jobs

  • Most array work is one of four scans: find the maximum, count matches, search for a value, or take an average.
  • Each one is a single for loop over the array, with a variable that remembers something.
  • Once you know these four, most array problems are a small change to one of them.

Handout · ⁨ورقة عمل⁩

Log in or create account · ⁨تسجيل الدخول أو إنشاء حساب⁩

IGCSE, A-Level & AP