7.1. Vectors - JulTob/Ada GitHub Wiki

You can create vector types on different ways

type Vector is array (1 .. 4) of Integer;
   for VECTOR'SIZE USE 4 * INTEGER'SIZE;

You can also declare vectors as records

type Vect is record
   x : Integer;
   y : Integer;
   z : Integer;
   t : Integer;
   end record;
for Vect'Size use 4 * Integer'Size;

Example

procedure Hello_Vectors is

  --You can declare vectors with any type you have made
  type Day_Type is (Sun, Mon, Tue, Wed, Thu, Fri, Sat)
  Work_Hors: array(Day_Type) of Natural;
  
begin
  Work_Hours:= (0,8,8,8,8,8,0)
  
  Work_Hours:= (Sat=>0, Sun=>0, others=>8);
  for Day in Mon..Fri loop
    Work_Hours(Day):=8;
  end loop;

--Holidays!
  for Day in Day_Type loop
    Work_Hours(Day):=2;
  end loop;


end Hello_Vectors;