main = getLine >>=putStrLn.calc.map (read::String->Int).words
		where
		calc :: [Int]->String
		calc1 [a,b,c]=if a<b
			then [a,b,c]
			else [b,a,c]
		calc2 [a,b,c]=if b<c
			then [a,b,c]
			else [a,c,b]
		calc=unwords.map show.calc1.calc2.calc1