with Ada.Exceptions; use Ada.Exceptions; with Ada.Text_IO; use Ada.Text_IO; with Ada.Integer_Text_IO; use Ada.Integer_Text_IO; procedure exceptions3 is i: Integer; Too_Large, Too_Small: Exception; begin put("Enter a number in range 1 .. 10 : "); get(i); if i < 1 then raise Too_Small; elsif i > 10 then raise Too_Large; end if; put(i); new_line; exception when e: Too_Large | Too_Small => put(Exception_Name(e)); put_line(". Invalid Number. Bailing out!"); when e: others => put(Exception_Name(e)); put_line(". Bailing out!"); end exceptions3; -- SAMPLE RUN 1 -- Enter a number in range 1 .. 10 : 0 -- EXCEPTIONS3.TOO_SMALL. Invalid Number. Bailing out! -- -- SAMPLE RUN 2 -- Enter a number in range 1 .. 10 : 11 -- EXCEPTIONS3.TOO_LARGE. Invalid Number. Bailing out!