import java.util.ArrayList;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {

		Scanner scanner = new Scanner(System.in);

		ArrayList<String> resultList = new ArrayList<String>();

		boolean flg = true;

		while (flg) {
			int a = scanner.nextInt();
			int b = scanner.nextInt();

			if (a > b) {
				resultList.add(b + " " + a);
			} else if (a < b) {
				resultList.add(a + " " + b);
			} else if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			}

		}

		for (int i = 0; i < resultList.size(); i++) {
			System.out.println(resultList.get(i));
		}
	}
} import java.util.ArrayList; ArrayList java.util import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {

		Scanner scanner = new Scanner(System.in);

		ArrayList<String> resultList = new ArrayList<String>();

		boolean flg = true;

		while (flg) {
			int a = scanner.nextInt();
			int b = scanner.nextInt();

			if (a > b) {
				resultList.add(b + " " + a);
			} else if (a < b) {
				resultList.add(a + " " + b);
			} else if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			}

		}

		for (int i = 0; i < resultList.size(); i++) {
			System.out.println(resultList.get(i));
		}
	}
} Main public static void main(String[] args) {

		Scanner scanner = new Scanner(System.in);

		ArrayList<String> resultList = new ArrayList<String>();

		boolean flg = true;

		while (flg) {
			int a = scanner.nextInt();
			int b = scanner.nextInt();

			if (a > b) {
				resultList.add(b + " " + a);
			} else if (a < b) {
				resultList.add(a + " " + b);
			} else if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			}

		}

		for (int i = 0; i < resultList.size(); i++) {
			System.out.println(resultList.get(i));
		}
	} main {

		Scanner scanner = new Scanner(System.in);

		ArrayList<String> resultList = new ArrayList<String>();

		boolean flg = true;

		while (flg) {
			int a = scanner.nextInt();
			int b = scanner.nextInt();

			if (a > b) {
				resultList.add(b + " " + a);
			} else if (a < b) {
				resultList.add(a + " " + b);
			} else if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			}

		}

		for (int i = 0; i < resultList.size(); i++) {
			System.out.println(resultList.get(i));
		}
	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) ArrayList<String> resultList = new ArrayList<String>(); resultList new ArrayList<String>() boolean flg = true; flg true while (flg) {
			int a = scanner.nextInt();
			int b = scanner.nextInt();

			if (a > b) {
				resultList.add(b + " " + a);
			} else if (a < b) {
				resultList.add(a + " " + b);
			} else if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			}

		} flg {
			int a = scanner.nextInt();
			int b = scanner.nextInt();

			if (a > b) {
				resultList.add(b + " " + a);
			} else if (a < b) {
				resultList.add(a + " " + b);
			} else if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			}

		} int a = scanner.nextInt(); a scanner.nextInt() scanner.nextInt scanner int b = scanner.nextInt(); b scanner.nextInt() scanner.nextInt scanner if (a > b) {
				resultList.add(b + " " + a);
			} else if (a < b) {
				resultList.add(a + " " + b);
			} else if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			} a > b a b {
				resultList.add(b + " " + a);
			} resultList.add(b + " " + a) resultList.add resultList b + " " + a b + " " + a b " " a if (a < b) {
				resultList.add(a + " " + b);
			} else if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			} a < b a b {
				resultList.add(a + " " + b);
			} resultList.add(a + " " + b) resultList.add resultList a + " " + b a + " " + b a " " b if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			} 0 == a && 0 == b 0 == a 0 a 0 == b 0 b {
				flg = false;
				break;
			} flg = false flg false break; if(a == b){
				resultList.add(a + " " + b);
			} a == b a b {
				resultList.add(a + " " + b);
			} resultList.add(a + " " + b) resultList.add resultList a + " " + b a + " " + b a " " b for (int i = 0; i < resultList.size(); i++) {
			System.out.println(resultList.get(i));
		} int i = 0; int i = 0; i 0 i < resultList.size() i resultList.size() resultList.size resultList i++ i++ i {
			System.out.println(resultList.get(i));
		} {
			System.out.println(resultList.get(i));
		} System.out.println(resultList.get(i)) System.out.println System.out System System.out resultList.get(i) resultList.get resultList i String[] args args public class Main {
	public static void main(String[] args) {

		Scanner scanner = new Scanner(System.in);

		ArrayList<String> resultList = new ArrayList<String>();

		boolean flg = true;

		while (flg) {
			int a = scanner.nextInt();
			int b = scanner.nextInt();

			if (a > b) {
				resultList.add(b + " " + a);
			} else if (a < b) {
				resultList.add(a + " " + b);
			} else if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			}

		}

		for (int i = 0; i < resultList.size(); i++) {
			System.out.println(resultList.get(i));
		}
	}
} public class Main {
	public static void main(String[] args) {

		Scanner scanner = new Scanner(System.in);

		ArrayList<String> resultList = new ArrayList<String>();

		boolean flg = true;

		while (flg) {
			int a = scanner.nextInt();
			int b = scanner.nextInt();

			if (a > b) {
				resultList.add(b + " " + a);
			} else if (a < b) {
				resultList.add(a + " " + b);
			} else if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			}

		}

		for (int i = 0; i < resultList.size(); i++) {
			System.out.println(resultList.get(i));
		}
	}
} Main
import java.util.ArrayList;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {

		Scanner scanner = new Scanner(System.in);

		ArrayList<String> resultList = new ArrayList<String>();

		boolean flg = true;

		while (flg) {
			int a = scanner.nextInt();
			int b = scanner.nextInt();

			if (a > b) {
				resultList.add(b + " " + a);
			} else if (a < b) {
				resultList.add(a + " " + b);
			} else if (0 == a && 0 == b) {
				flg = false;
				break;
			}else if(a == b){
				resultList.add(a + " " + b);
			}

		}

		for (int i = 0; i < resultList.size(); i++) {
			System.out.println(resultList.get(i));
		}
	}
}