program netikra_moneta;
  var n, sverimai: integer;
begin
  readln (n);
  sverimai := 0;
  while n > 3 do
    begin
      sverimai := sverimai + 1;
      if n mod 3 = 0
         then n := n div 3
         else n := n div 3 + 1;
    end;
  { ma‘iau nei keturioms monetoms u‘tenka vieno sv‚rimo }
  sverimai := sverimai + 1;
  writeln (sverimai);
end.