#include <bits/stdc++.h>
using namespace std;
const int inf = 0x3f3f3f3f;
int main() {
  std::ios::sync_with_stdio(false), cin.tie(0), cout.tie(0);
  int n;
  cin >> n;
  n += 2;
  vector<pair<int, int> > v;
  for (int i = 1; i <= n; i++)
    for (int j = i; j <= i + 2; j++) v.push_back({i, j});
  cout << (int)v.size() - 2 << '\n';
  for (int i = 1; i < (int)v.size() - 1; i++)
    cout << v[i].first << ' ' << v[i].second << '\n';
  return 0;
}
