#include "bits/stdc++.h" using namespace std; int main() { long long N; cin >> N; if (N % 2 == 1) { cout << 7; N-=3; } for (int i = 0; i * 2 < N; i++) { cout << 1; } cout << endl; }