solve n 
    | (r >= 1) && (r <= 6) = 2 * q + 1
    | (r >= 7) && (r <= 10) = 2  * q + 2
    | otherwise = 2 * q
    where
        (q, r) = quotRem n 11

main = do
    n <- readLn :: IO Int
    print $ solve n