Arrays

Declaration and Assignment


Aggregate Assignment


Array Types and Assignment


Array Declaration and Allocation


Arrays are NOT of Reference Type


Equality of Arrays


MultiDimensional Arrays


Example Program


Array Slices


Array Attributes and Operations



Unconstrained Arrays


Unconstrained 2D Arrays


Declaring Array Sizes at Runtime

...
   type ListType is 
      array(Integer range <>) of Float;
...
begin
   ...
   get(n);
   declare
      list1: ListType(1 .. N);
   begin
      for i in list1'range loop
         get(list1(i));
      end loop;
      for i in reverse list1'range loop
         put(list1(i), 0, 1, 0);
         new_line;
      end loop;
   end
   -- list1 not defined here