--  Array aggregates over an array's components (T25b): filtered, and not, each built in one
--  pass; bounds from the index subtype's first, as GNAT gives them.
with Ada.Text_IO; use Ada.Text_IO;
procedure Main is
   type Arr is array (Positive range <>) of Integer range 0 .. 100;
   A : constant Arr := (3, 1, 4, 1, 5, 9, 2, 6);
   Big : constant Arr := [for X of A when X > 3 => X];
   Doubled : constant Arr := [for X of A => X / 2];
begin
   Put_Line (Integer'Image (Big'First) & Integer'Image (Big'Last) & Integer'Image (Big (Big'First)));
   for X of Big loop
      Put (Integer'Image (X));
   end loop;
   New_Line;
   Put_Line (Integer'Image (Doubled'Length) & Integer'Image (Doubled (8)));
end Main;
