#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  if (n == 2) {
    cout << 1;
    return 0;
  } else if (n == 3) {
    cout << 7;
    return 0;
  } else if (n == 4) {
    cout << 11;
    return 0;
  } else if (n >= 5) {
    if (n % 2) {
      cout << 7;
      n -= 3;
      for (int i = 0; i < n; i += 2) cout << 1;
    } else {
      for (int i = 0; i < n; i += 2) cout << 1;
    }
  }
}
