#include <bits/stdc++.h>
using namespace std;
const int INF = 2147483647;
int qread() {
  int w = 1, c, ret;
  while ((c = getchar()) > '9' || c < '0') w = (c == '-' ? -1 : 1);
  ret = c - '0';
  while ((c = getchar()) >= '0' && c <= '9') ret = ret * 10 + c - '0';
  return ret * w;
}
int n;
int main() {
  n = qread();
  if (n & 1) putchar('7'), n -= 3;
  for (int i = 1; i <= n / 2; i++) putchar('1');
  puts("");
  return 0;
}
