with Ada.Text_IO, Ada.Integer_Text_IO, Ada.Float_Text_IO;
 use Ada.Text_IO, Ada.Integer_Text_IO, Ada.Float_Text_IO;

procedure main is
   A: Integer;
   B: Integer;
begin
   get(A);
   get(B);
   if (A <= 9 and then B <= 9) then put(A * B, 0);
   else put(-1, 0);
   end if;
end main;