N = int(input()) ans = [] while(N > 3): N -= 2 ans.append("1") ans.append("7" if N == 3 else "1") print("".join(ans[::-1]))