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

class Program {
    static void Main() {
        int n = int.Parse(Console.ReadLine());
        string s = "";
        if (n % 2 == 1) {
            s += "7";
            n -= 3;
        }
        for (int i = n; i >= 2; i -= 2) {
            s += "1";
        }
        Console.WriteLine(s);
    }
}