#include <cassert>
#include <cstdlib>
#include <iostream>

using namespace std;

int main(int argc, char* argv[]) {
    assert(argc == 3);
    int n = atoi(argv[1]);
    int seed = atoi(argv[2]);
    (void)seed;

    cout << n << '\n';
    for (int i = 0; i < n; i++) {
        cout << 0 << ' ' << i + 1 << '\n';
    }

    return 0;
}
