import java.util.Scanner;
import java.util.InputMismatchException;

public class MaximumMatching {
    public static void main(String[] args){
        Scanner scanner = new Scanner(System.in);
        try{
            //数値を入力して範囲をチェックする
            int N = scanner.nextInt();
            if(N < 2 || N > Math.pow(10,5)){
                System.out.println("Nは2以上10の5乗以下で入力してください");
                System.exit(0);
            }
            
            //入力された値が偶数か奇数かのチェック
            if( N % 2 == 0){
                for(int i = 0 ; i < N / 2 ; i++){
                    System.out.print("1");    
                    }
            }else{
                for(int j = 0 ; j < (N - 1) / 2 ; j++){
                    if( j == 0){
                        System.out.print("7");
                    }else{
                        System.out.print("1");
                    }
                }
            }
            
        }catch(InputMismatchException e){
            System.out.println("数字を入力してください");
        }catch(Exception E){
            System.out.println("予期せぬエラーです");
        }
    }
}