import sys N = int(input()) a = 0 if N % 2 == 0:#偶数 if N == 0: a = 0 if N >= 2: a = N / 2 else: if N == 1: a = 0 if N >= 3: N -= 3 a = N / 2 sys.stdout.write('7') for i in range (int(a)): sys.stdout.write('1') print()