#include <bits/stdc++.h>
using namespace std;
int gcd(int a, int b) {
  if (a == 0) return b;
  return gcd(b % a, a);
}
int binarysearch(int a[], int ele, int n) {
  int beg = 0, end = n, mid, ans;
  while (beg <= end) {
    mid = beg + (end - beg) / 2;
    if (a[mid] > ele) {
      ans = mid;
      end = mid - 1;
    } else
      beg = mid + 1;
  }
  return ans;
}
bool comp(vector<int> a, vector<int> b) { return a[1] > b[1]; }
long long rad(long long a, long long b) { return pow(a, 2) + pow(b, 2); }
int main(void) {
  int n;
  cin >> n;
  if (n & 1) {
    cout << 7;
    n -= 3;
  }
  for (int i = 0; i < n / 2; i++) cout << 1;
  return 0;
}
