import Control.Applicative main :: IO () main = solve <$> readLn >>= putStrLn solve :: Int -> String solve n | n == 0 = "0" | otherwise = "0." ++ (take n (cycle "142857"))