import java.io.*;
import java.util.*;

public class TestsGen {

	static int done = 0;
	static ArrayList<Integer> data = new ArrayList<Integer>();
	static final Random rand = new Random(556668949239L);

    static final long MAX_N = (long)1e18;
    static final long MAX_K = (long)1e9; 

	static void print(long n, long k) throws IOException {
		done++;
		System.err.println(done);
		PrintWriter out;
		if (done < 10)
			out = new PrintWriter("0" + String.valueOf(done));
		else
			out = new PrintWriter("" + String.valueOf(done));
		out.println(n + " " + k);
		out.close();
	}


	public static void main(String[] args) throws IOException {
        // Simple test
        print(20, 7);

        // Small tests
        for (int i = 10; i < 101; i += 10)
            print(i, rand.nextInt(14) + 2);
        
        // Middle tests
        for (int i = 1000; i < 10001; i += 1000)
            print(i, rand.nextInt(1000) + 100);

        // Big tests
        for (int i = 0; i < 10; i++)
            print(MAX_N / 2 + rand.nextInt(), rand.nextInt((int)MAX_K / 2) + MAX_K / 2);

        // Special tests
        print(MAX_N, (1L <<28) * 3);
        print(MAX_N, 999999937);
        print(MAX_N, MAX_K);
        print(MAX_N, 31627 * 31607);
        print(MAX_N, 31607 * 31607);
        return;
	}
}
