# 
loop = true

while loop do
    a, b = gets.split.map &:to_i
    if a == 0 and b == 0
        break
    end
    if a < b
        puts [a,b].join " "
    else
        puts [b,a].join " "
    end
end

