Line break: synthesis

 Why revise a synthesis? 

As already mentioned in this course, mastering line breaks should become spontaneous and perfect, a bit like shifting gears when you're learning to drive. You don't even have to think about it. That's what you have to achieve.

The computer itself is a robot that contains its own internal program to execute the program you've encoded. This internal program will ask the computer, after executing a line, to skip to the next line or to jump to another line according to the rules below.

If you don't know this perfectly, you won't be able to program or code correctly. The following is therefore of the utmost importance, and you should be able to master it spontaneously.

Here's a summary of everything we've seen in algorithmics about line breaks...

If we encounter...ResultWe perform the action...
InstructionContinue to next line
IFTrueContinue to next line
IFFalseNo ELSE? Jump after the corresponding END IF
An ELSE? Jump after the corresponding ELSE
ELSEJump after the corresponding END IF
END IFContinue to next line
REPEATContinue to next line
UNTILTrueContinue to next line
UNTILFalseJump after the corresponding REPEAT
WHILETrueContinue to next line
WHILEFalseJump after the corresponding END WHILE
END WHILEAutomatically jump to the corresponding WHILE

Note that, in all cases where the result of the verification is True, the computer will continue execution of the program on the next line.

Please make sure you understand these essential rules.

Return