using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace petlja3_2020
{
    class Program
    {
        static void Main(string[] args)
        {
            int brojTrojki = int.Parse(Console.ReadLine());
            if (brojTrojki <= 10)
            {
                switch (brojTrojki)
                {
                    case 1:
                        Console.WriteLine("3\n0 0\n1 0\n2 0");
                        break;
                    case 2:
                        Console.WriteLine("5\n0 2\n0 1\n0 0\n1 0\n2 0");
                        break;
                    case 3:
                        Console.WriteLine("7\n0 0\n0 1\n0 2\n1 0\n2 0\n-1 -1\n-2 -2");
                        break;
                    case 4:
                        Console.WriteLine("4\n0 0\n1 1\n2 2\n3 3");
                        break;
                    case 5:
                        Console.WriteLine("6\n0 0\n1 1\n2 2\n3 3\n-1 1\n-2 2");
                        break;
                    case 6:
                        Console.WriteLine("8\n0 0\n1 1\n2 2\n3 3\n-1 1\n-2 2\n0 -1\n0 -2");
                        break;
                    case 7:
                        Console.WriteLine("8\n0 0\n1 1\n-1 1\n-1 -1\n0 -1\n1 -1\n0 -2\n0 -3");
                        break;
                    case 8:
                        Console.WriteLine("9\n0 0\n0 1\n0 2\n1 0\n1 1\n1 2\n2 0\n2 1\n2 2");
                        break;
                    case 9:
                        Console.WriteLine("5\n-2 0\n-1 0\n0 0\n1 0\n2 0");
                        break;
                    case 10:
                        Console.WriteLine("10\n0 0\n0 1\n0 2\n1 0\n-1 0\n0 -2\n-1 -3\n1 -1\n2 -2\n3 -3");
                        break;
                }
                return;
            }
        }
    }
}
/*
 * ?????? 1
????
8
?????
9
0 0
0 1
0 2
1 0
1 1
1 2
2 0
2 1
2 2
?????? 2
????
2
?????
5
0 2
0 1
0 0
1 0
2 0
?????? 3
????
4
?????
4
0 0
1 1
2 2
3 3
 * */