#include<bits/stdc++.h>
using namespace std;
#define rep(i, k, n) for (int i = k; i < (int)(n); i++)
#define rep_(i,k,n) for(int i=k-1;i >=(int) n ;i--)



int main(){
  int N; cin >> N;
  int l1,l2;
  l1 = N % 2;
  l2 = (N-l1)/2;
  
  if(l1)
    cout <<7;
  else
    cout <<1;

  rep(i,0,l2-1)
    cout << 1 ;
  
  cout << endl;
}