
7
introduCtion
in Figure1.7. Loop is actually a variation of if- then- else logic. e common loops
include for- loop and do- loop. e variable used in a loop to control the execution of
the loop is called a counter.
1.4.7 Module
A large program must be divided into modules to make the program easy to debug.
Also, a module can be reused. Here, a module could be a paragraph of instructions,
an independent function, or a class, depending upon the specific language in discus-
sion. An instruction in a module can call another module to accomplish a specific task
carried out by the called module, as illustrated in Figure1.8. A module has its name,