import math
N = int(input())
num = 1
if N % 2 == 0:
    while N > 2:
        num = 10 * num + 1
        N = N - 2
    print(num)
else:
    N = N - 1
    while N > 2:
        num = 10 * num + 1
        N = N - 2
    num_size = int (math.log10(num))
    num = num + 6 * (10**num_size)
    print(num)