while True:

    a,b = list(map(int, input().split()))

    if a == 0 and b ==0:

        break

    elif a < b:

        print((a,b))

    else:

        print((b,a))
i = 0

while True:

    a,b = list(map(int, input().split()))

    if (a == 0) and (b == 0):

        break

    elif a < b:

        print((str(a)+' '+str(b)))

        i = i + 1

    else:

        print((str(b)+' '+str(a)))

        i = i + 1

while True:
    a, b = list(map(int, input().split()))
    if a == 0 and b == 0:
        break
    elif a < b:
        print((a, b))
    else:
        print((b, a))

i = 0
while True:
    a, b = list(map(int, input().split()))
    if (a == 0) and (b == 0):
        break
    elif a < b:
        print((str(a) + " " + str(b)))
        i = i + 1
    else:
        print((str(b) + " " + str(a)))
        i = i + 1

+i = 0 -    if a == 0 and b == 0: +    if (a == 0) and (b == 0): -        print((a, b)) +        print((str(a) + " " + str(b))) +        i = i + 1 -        print((b, a)) +        print((str(b) + " " + str(a))) +        i = i + 1