--  The library's hash map (E3): keys added, the table growing past half full, a key's element
--  replaced in place, and what the model says of them
with Ada.Text_IO; use Ada.Text_IO;
with Verada.Containers.Hash_Maps;

procedure Main is
   package Maps is new Verada.Containers.Hash_Maps (Integer);
   M : Maps.Map;
begin
   Maps.Include (M, 7, 1);
   Maps.Include (M, 14, 2);
   Maps.Include (M, 21, 3);
   Maps.Include (M, 28, 4);
   Maps.Include (M, 35, 5);
   Maps.Include (M, 42, 6);
   Maps.Include (M, 49, 7);
   Maps.Include (M, 56, 8);
   Maps.Include (M, 63, 9);
   Maps.Include (M, 14, 200);
   if Maps.Contains (M, 14) then
      Put_Line (Integer'Image (Maps.Element (M, 14)));
   end if;
   Put_Line (Integer'Image (Maps.Length (M)) & Boolean'Image (Maps.Contains (M, 15)));
end Main;
