6. NS BASIC Tech Note                                     September 14, 
1994

How to use multi-dimensional arrays                        
--------------------------------------------------------------------------

Multidimensional arrays are easy to implement in NS BASIC. To do so
effectively requires a bit more information than is contained in the NS 
BASIC
Handbook, dated July 1, 1994.

To refer to element (i,j) in a 2 dimensional array A, do the following:

A[i][j]

To initialize such an array, do

DIM A[rows]
FOR i=0 to rows
  A[i]=ARRAY(cols,0)
NEXT i

ARRAY(x,y) is a handy function not mentioned in the July 1 Handbook. It
returns an array of x elements, each set to the value y.

In this same fashion, arrays of greater than two dimensions can be
constructed.