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