var n: integer;
begin
Read(n);
if (n mod 10 = 1) and (n<>11) then write (n, " ", "рік")
else if ((n mod 10 = 2) or (n mod 10 = 3) or (n mod 10 = 4)) and (n>=12) and (n<=14) then write (n, " ", "роки")
else write(n, " ", "років");
end.
var n: integer;
begin
Read(n);
if (n mod 10 = 1) and (n<>11) then write (n, " ", "рік")
else if ((n mod 10 = 2) or (n mod 10 = 3) or (n mod 10 = 4)) and (n>=12) and (n<=14) then write (n, " ", "роки")
else write(n, " ", "років");
end.