# -*- coding: utf-8 -*- def solve(n): result = 0 digit = 1 if n % 2 == 0: for i in range(0, n // 2): result += digit digit *= 10 else: for i in range(0, n // 2): result += digit if i < (n // 2) - 1 else 7 * digit digit *= 10 print(result) n = int(input()) solve(n)