Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Fixed some OCR mistakes in the vector examples
Style
.key
{
 border-right: #000000 1px solid;
 padding-right: 1px;
 border-top: #000000 1px solid;
 padding-left: 1px;
 font-size: 12px;
 font-weight: normal;
 border-left: #000000 1px solid;
 border-bottom: #000000 1px solid;
}

In this manual, anything displayed on the Cambridge Z88 screen is shown in a computer typeface, such as

Name of file to save

Anything that you should type at the keyboard is shown in a different typeface to designate the keyboard keys; for example

You are invited to a party

The keys on the keyboard with a special function are shown in the text with key legends. So, for example, if you are asked to type

...

ENTER

...

ENTER

...

In general, references to menu headings are in bold caps; for example LAYOUT.

References to individual commands are in bold; for example Save or Load.

References to options displayed by a command are in italics; for example Save only range of columns.

...

CTRL

...

The cursor keys are represented as Image RemovedImage RemovedImage Removed and Image Removed key on normal PC.

 

Info

We're currently working on this page, we hope to have it done soon.

 

The following operators may be used as part of expressions.

Arithmetic operators

The arithmetic operators take two numbers as operands.

+add -subtract
*multiply /divide
^raise to the power   

Relational operators

The relational operators can compare numbers, and return a logical value of FALSE=O and TRUE=-1.

less than =equal to
<=less than or equal to >greater than
<>not equal to >=greater than or equal to

Logical operators

The logical operators operate on numeric or logical values. Boolean FALSE is taken as zero, TRUE as —1.

Indirection operators

The following operators allow the programmer to access memory directly (called PEEK in other versions of BASIC) or to alter the contents of specified memory locations (called POKE in other BASICs).

...

0123456789101112
vec?0vec?111vec?2vec?3vec?4vec?5vec?6vec?7vec?8vec?9vec?10vec?11vec?12

Note that ?vec is an alternative way of writing vec?0. A typical manipulation might be

...

Alternatively the vector could be addressed as 4 four-byte words:

0123456789101112
vec?100vec?144vec?188vec?12

Finally, the string indirection operator allows a string to be stored directly into an area of memory. For example:

...

Individual characters can be accessed with the ? operator.

Order of precedence

The order of precedence of the operators is as follows:

Group 1 - unary minus 
  ()  brackets
   NOT  logical NOT
      
Group 2  ^  raise to the power
      
Group 3  *  multiply
   /  divide
      
Group 4  +  add
   -  subtract
      
Group 5  <  less than
   =  equal to
   <=  less than or equal to
   >  greater than
   <>  not equal to
   >=  greater than or equal to
      
Group 6  AND  Logical AND
     

...

Group 1

Group 2

Group 3

Group 4

...

Group

...

7

unary minus brackets

logical NOT

A    raise to the power

multiply divide

+    add subtract

less than

equal to

less than or equal to greater than

not equal to

greater than or equal to

AND Logical AND

OR    Logical OR

...

 OR Logical OR
  EOR Logical Exclusive-OR

 

NOT

so, for example, A-B*CAD C^D is equivalent to A-(B*(CADC^D)).