#include "testlib.h"
#include <bits/stdc++.h>
using namespace std;

const int max_coord = int(1e4);

int main (int argc, char *argv[])
{
    registerGen(argc, argv, 1);

    const int n = opt<int>("n");

    set<pair<int, int>> pts;
    while (int(pts.size()) < n)
    {
        pair<int, int> cur;
        cur.first = rnd.next(0, max_coord);
        cur.second = rnd.next(0, max_coord);
        pts.insert(cur);
    }

    vector<pair<int, int>> v(pts.begin(), pts.end());
    shuffle(v.begin(), v.end());

    cout << n << endl;
    for (int i = 0; i < n; i++)
        cout << v[i].first << ' ' << v[i].second << "\n";
}
