#include <bits/stdc++.h>
using namespace std;
int n;
string s;
int main() {
  cin >> n;
  if (n % 2 == 1) {
    s += '7';
    n -= 3;
  }
  while (n > 0) {
    s += '1';
    n -= 2;
  }
  cout << s;
  return 0;
}
