N = int(input()) ans = "" if N%2==0: ans = "1"*(N//2) else: ans = "7" ans += "1"*((N-3)//2) print(int(ans))