Arrays

    Arrays are declared as

      var mi : array(char)[][];
          vb : array(byte)[];

    The size is given not in the type declaration but in the array creation:

      mi = array(char)[][].new(30, 50);
      vb = array(byte)[].new(Max);

    Variable mi may refer to any char array of two dimensions. Each array class supports the method getSize, which returns the number of array elements. There are other methods with common array operations. These are not discussed here.
 
 

What is new ?

    The originality of Green arrays is related to the introspective reflection library. However, it should be noted that the array size does not belong to the array type and  this is reflected in the syntax: the size is passed as a parameter to method new. A method that expects an array "array(char)[]" as a parameter, accepts char arrays of any size as parameters.

Return