11.1 Statements controlling the program flow

This chapter describes all statements offered by Hollywood, which are used to control the program flow. It is very important that you know these control structures because they can make your program much more readable. We can categorize the Hollywood control structures into two groups:

1) Conditional blocks: They are used to check if a specific expression is true (non-zero) or false (zero). This is very important because your program needs to make decisions all the time. The following kinds of conditional blocks are available:


2) Loops: They are used to repeat certain portions of your code. Imagine you want to print the numbers from 1 to 100. You could type in the Print() command a hundred times for that, but you could also use a simple For loop that calls Print() a hundred times. The following loop structures are available:


Show TOC