N=int(input()) ans=[] if N%2==0: for i in range(N//2): ans.append("1") elif N%2==1: ans.append("7") if N>=5: for i in range(N//2): ans.append("1") print("".join(ans))