Repetition (Loop) Control Structure

សម្ព័ន្ធភាព៖ UNITEN
ដំណោះស្រាយ៖ ក្រុម | រយៈពេល៖ មួយទៅពីរម៉ោង

ទិដ្ឋភាពទូទៅ


គោលដៅ

To make students learn how to repeat the execution of the same code multiples times while the specified condition or criteria is fulfilled. Repetition control structure is one of the main control structure in programming beside sequence and selection structures.

វត្ថុបំណងការសិក្សា

By the end of this activity, students will be able to: - explain the 3 kinds repetition control structures - while, do while and for - explain the counter-controlled and sentinel-controlled repetition structure - apply the concepts of repetition control structure into a practical problem

បរិបទ

In programming, there are many situations in which it is necessary to repeat the execution of a set of statements. There are three looping (repetition) structures: while, for, and do…while. It allows repeating statements over and over until certain conditions are met. Using this construct of programming, programmers do not need to write the same set of statements multiple times.