N = int(input())

Q = N // 2
R = N % 2
MaxNum = 0

if R == 0:
    MaxNum = '1' * Q
else:
    MaxNum = '7' + '1' * (Q - 1)

print(MaxNum)