module Main where


main = do
  x <- readLn :: IO Integer
  print $ solve x

solve :: Integer -> Integer
solve x
  | x `mod` 11 == 0 = (x `div` 11) * 2
  | x `mod` 11 <= 6 = (x `div` 11) * 2 + 1
  | otherwise = (x `div` 11) * 2 + 2
