with Ada.Text_IO; procedure ArrayTest is type Index_Type is new Positive; package Index_IO is new Ada.Text_IO.Integer_IO (Index_Type); type Element_Type is new Natural; type My_Array_Type is array (Index_Type range <>) of Element_Type; type My_Array_Access is access My_Array_Type; My_Index : Index_Type; My_Array : My_Array_Access; begin Ada.Text_IO.Put ("Please enter maximum Index: "); Index_IO.Get (My_Index); My_Array := new My_Array_Type (1..My_Index); -- work with My_Array... end ArrayTest;