import System.IO main = main' (0,0) where main' (x,y) = do putStrLn (unwords (map show [x,y])) hFlush stdout m <- readLn putStrLn (unwords (map show [m,0])) hFlush stdout mx <- readLn putStrLn (unwords (map show [m - div mx 2, div mx 2])) hFlush stdout mx <- readLn putStrLn (unwords (map show [m - div mx 2 + 1, div mx 2 - 1])) hFlush stdout mx <- readLn putStrLn (unwords (map show [m - div mx 2 - 1, div mx 2 + 1])) hFlush stdout