N=int(input()) s='' while N>3: s+='1' N-=2 print(('1','7')[N==3]+s)