with Ada.Text_IO; use Ada.Text_IO;
with Ada.Integer_Text_IO; use Ada.Integer_Text_IO;

procedure Solve is
   A : Integer;
   P : Integer;
begin
   Get (A);
   Get (P);
   P := P+A*3;
   Put_Line (Integer'Image (P/2));
end Solve;