n = 1000 W = 1000 print(n, W) print(1, 10000) for w in range(2, n + 1): v = (w - 1) * 10001 print(v, w)