Bee Learnt Logo
Bee Learnt
FeatureBrowse allPricingAboutSupport
Bee Learnt

Bee Learnt gives South African Grade 10–12 learners a cleaner route from classwork to NSC readiness — with parents and tutors supporting the journey.

WhatsApp: 0685537312

Support email: admin@beelearnt.co.za

Learn
FeaturesBrowse subjectsPricing
Get started
Create accountSign inContact support
Company
About Bee LearntAdvertisingContact
Legal
Privacy policyTerms of serviceCookie policyAd choices

© 2026 Bee Learnt. All rights reserved.

CAPS aligned · Grades 10–12 · NSC ready

Privacy choices

Allow analytics and advertising services to help us understand site usage and measure campaigns.

Privacy Policy
  1. Subjects
  2. /
  3. Information Technology
  4. /
  5. Information Technology Grade 10 — Practical
  6. /
  7. Introduction to Programming (Delphi)
  8. /
  9. Iteration (loops)
Grade 10 · Practical

Iteration (loops)

Introduction to Programming (Delphi) · about 4 min

Educational overview for Iteration (loops)Visual overview: Iteration (loops)
1 MIN READ
2 study sections · pause after each one and recall the key idea

Iteration repeats a block of code. Choose the loop that matches whether you know the number of repetitions in advance.

Key points
  • `for i := 1 to n do` — a KNOWN, fixed number of repetitions (a counter loop).
  • `while condition do` — repeat while a condition holds; tests BEFORE each pass (may run zero times).
  • `repeat … until condition` — tests AFTER each pass, so it always runs at least once.
  • Guard against infinite loops: something inside a while/repeat must eventually make the condition stop.
Key terms
  • Loop / iteration — repeating a block of statements.
  • Counter — a variable that counts the passes of a loop.
  • Infinite loop — a loop whose stop condition is never met.
EXAM TIP

"read values until the user enters 0" is a WHILE (unknown count); "do this for each of the 12 months" is a FOR (known count).


Previous

Selection (if statements)