table :: [Int]
table = loop 0 []
  where
    loop i xs
      | i > 86 = xs
      | i == 0 = loop (i+1) (2:xs)
      | i == 1 = loop (i+1) (1:xs)
      | otherwise = loop (i+1) (a+b:xs)
        where
          [a,b] = take 2 xs
      
main = do
  n <- readLn :: IO Int
  print $ table !! (86 - n)
