Top
Back: Type conversion and casting
Forward: Input and output
FastBack: Implemented algorithms
FastForward: Input and output
Up: The SINGULAR language
Top: Singular Manual
Contents: Table of Contents
Index: Index
About: About this document

3.5.6 Flow control

A block is a sequence of commands surrounded by { and }.
 
{
   command;
   ...
}
Blocks are used whenever SINGULAR is used as a structured programming language. The if and else structures allow conditional execution of blocks (see if, else). for and while loops are available for a repeated execution of blocks (see for, while). In procedure definitions, the main part and the example section are blocks as well(see proc).

5.2.2 break  
5.2.13 quit  
5.2.11 keepring  
5.2.6 export  
5.2.7 exportto  
5.2.9 if  
5.2.10 importfrom  
5.2.5 else  
5.2.8 for  
5.2.15 while  
4.17 proc  
5.2.14 return  
5.2.4 continue  


Top Back: Type conversion and casting Forward: Input and output FastBack: Implemented algorithms FastForward: Input and output Up: The SINGULAR language Top: Singular Manual Contents: Table of Contents Index: Index About: About this document
            User manual for Singular version 4.3.2, 2023, generated by texi2html.