main :: IO ()
main = do
    line <- getLine
    let
        nums = string2Ints line
    if [0,0] == nums
       then return ()
       else do
           putStrLn $ ints2String $ qsort $ string2Ints line
           main

string2Ints :: String -> [Int]
string2Ints str = map (\x -> read x :: Int) (words str)

qsort :: [Int] -> [Int]
qsort [] = []
qsort (n:ns) = (qsort lower) ++ [n] ++ (qsort upper)
    where
        lower = [x | x <- ns, x <= n]
        upper = [x | x <- ns, n <  x]

ints2String :: [Int] -> String
ints2String ns = unwords $ map show ns