while True:

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

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

		break

	elif (a < b):

		print((str(a) + " " + str(b)))

	else :

		print((str(b) + " " + str(a)))


while True:

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

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

		break

	else:

		if (a < b):

			print((str(a) + " " + str(b)))



		else :

			print((str(b) +" "+ str(a)))

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

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

-    if (a == 0) and (b == 0): +    if a == 0 and b == 0: -    elif a < b: -        print((str(a) + " " + str(b))) -        print((str(b) + " " + str(a))) +        if a < b: +            print((str(a) + " " + str(b))) +        else: +            print((str(b) + " " + str(a)))