

import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		while (true) {
			int num1 = scanner.nextInt();
			int num2 = scanner.nextInt();
			if (num1 == 0 && num2 == 0)
				break;
			else {
				if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1));
			}
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		while (true) {
			int num1 = scanner.nextInt();
			int num2 = scanner.nextInt();
			if (num1 == 0 && num2 == 0)
				break;
			else {
				if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1));
			}
		}
	}
} Main public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		while (true) {
			int num1 = scanner.nextInt();
			int num2 = scanner.nextInt();
			if (num1 == 0 && num2 == 0)
				break;
			else {
				if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1));
			}
		}
	} main {
		Scanner scanner = new Scanner(System.in);
		while (true) {
			int num1 = scanner.nextInt();
			int num2 = scanner.nextInt();
			if (num1 == 0 && num2 == 0)
				break;
			else {
				if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1));
			}
		}
	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) while (true) {
			int num1 = scanner.nextInt();
			int num2 = scanner.nextInt();
			if (num1 == 0 && num2 == 0)
				break;
			else {
				if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1));
			}
		} true {
			int num1 = scanner.nextInt();
			int num2 = scanner.nextInt();
			if (num1 == 0 && num2 == 0)
				break;
			else {
				if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1));
			}
		} int num1 = scanner.nextInt(); num1 scanner.nextInt() scanner.nextInt scanner int num2 = scanner.nextInt(); num2 scanner.nextInt() scanner.nextInt scanner if (num1 == 0 && num2 == 0)
				break;
			else {
				if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1));
			} num1 == 0 && num2 == 0 num1 == 0 num1 0 num2 == 0 num2 0 break; {
				if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1));
			} if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1)); num1 < num2 num1 num2 System.out.println(String.format("%s %s", num1, num2)) System.out.println System.out System System.out String.format("%s %s", num1, num2) String.format String "%s %s" num1 num2 System.out.println(String.format("%s %s", num2, num1)) System.out.println System.out System System.out String.format("%s %s", num2, num1) String.format String "%s %s" num2 num1 String[] args args public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		while (true) {
			int num1 = scanner.nextInt();
			int num2 = scanner.nextInt();
			if (num1 == 0 && num2 == 0)
				break;
			else {
				if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1));
			}
		}
	}
} public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		while (true) {
			int num1 = scanner.nextInt();
			int num2 = scanner.nextInt();
			if (num1 == 0 && num2 == 0)
				break;
			else {
				if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1));
			}
		}
	}
} Main


import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		while (true) {
			int num1 = scanner.nextInt();
			int num2 = scanner.nextInt();
			if (num1 == 0 && num2 == 0)
				break;
			else {
				if (num1 < num2)
					System.out.println(String.format("%s %s", num1, num2));
				else
					System.out.println(String.format("%s %s", num2, num1));
			}
		}
	}
}