N = int(input()) print(['7' + '1' * ((N-3)//2), '1' * (N//2)][N % 2 == 0])