12:30ч. - 14:30ч. (2ч) / 4 седмици
Зала "MindHub - Пловдив" - бул. Марица 69, ет. 3 Plovdiv
In this module students learn about cycles – program constructs used for the repetitive execution of a certain piece of code. We can loop any instruction or sequence of instructions a defined number of times or until a condition is met.
In this lesson students learn about the difference between consecutive and repetitive actions in the program. The concept of loop is introduced through examples from everyday life. Students learn about iteration and what it means to loop a cycle.
In this lesson students practice what they have learnt about loops so far and create various programs. The new thing here is the introduction of infinite loops. We explain the use of the Forever Loop and also why it is so important to programming. In this lesson students find out how, by using counter loops, they can repeat a certain instruction a defined number of times. Another aim of the lesson is for them to understand the Repeat until instruction, which repeats an instruction or a block of instructions until a certain action takes place.
Students learn about nested loops. They find out that in the body of each loop there can be random instructions, along with other loop operators. In this case by looping the outer cycle once we loop the inner one a certain number of times too. We can have both Counter and Decision loops in any program. Counter loops allow us to repeat instructions a certain number of times while decision loops execute a loops until a goal is reached. When used together they make writing code easier for us and reading the code easier for the computer.
This is a practice lesson and it helps students put to use all they have learnt in the module and successfully do a project.