# -*- coding: utf-8 -*- """ No.83 最大マッチング https://yukicoder.me/problems/no/83 """ import sys from sys import stdin input = stdin.readline def main(args): N = int(input()) if N % 2 == 0: print('1'*(N//2)) else: print('7'+'1'*((N-3)//2)) if __name__ == '__main__': main(sys.argv[1:])