N = int(input()) ans = '' while N >= 2: if N & 1: ans += '7' N -= 3 else: ans += '1' N -= 2 print(ans)