Topic: APLX Help : Help on APL language : APL Primitives : ⋄ Statement Separator
[ Previous | Next| Contents | Index | APL Home ]

www.microapl.co.uk

Statement Separator


The ("diamond") character acts as a statement separator, which allows you to place multiple statements on a single line. This works either in a function, or in desk-calculator mode. The left-most statement is executed first:

      QTY←4 ⋄ PRICE←2.5 ⋄ QTY×PRICE
10
      QTY
4
      PRICE
2.5

If an error occurs within one of the statements, execution is abandoned (the remaining statements are not executed).

The statement separator can be used with structured-control keywords:

      :Repeat 3 ⋄ "No!" ⋄ :End
No!
No!
No!

Topic: APLX Help : Help on APL language : APL Primitives : ⋄ Statement Separator
[ Previous | Next| Contents | Index | APL Home ]