uses crt;
var i: integer;
begin
     for i:=42004 to 42994 do
         if (i mod 72=0) and (i mod 10=4) then writeln(i);
end.