6.1.4 Quit a Loop

Sometimes it is also very convenient to exit a loop in the middle of the iteration, and to jump to the follow up statement. This can be done with loops having a break feature. This feature gives access to a Break procedure by which to jump out of the loop.

The break feature is also very useful to write while or until loops:

while Test do Statement ==>  for  
                                 break:Break  
                              do 
                                if Test  
                                then Statement  
                                else {Break}  
                                end 
                             end


Denys Duchier, Claire Gardent and Joachim Niehren
Version 1.3.99 (20050412)