Rules for writing the program
Procedure
Use debugging feature
To know how your program is executing step by step and to locate errors in the program.
By pressing F8 function key it starts debugging, if needed the program is recompiled and then frist line of the program which is to be executed is highlighted.
Each time when you press F8 key the highlight moves to the next line and continue pressing F8 key till last line of the program is executed.