defmodule Main do def main do input = IO.binread(:all) |> String.trim_trailing("\n") n = String.to_integer(input) x = if rem(n, 2) == 0 do String.duplicate("1", div(n, 2)) else "7" <> String.duplicate("1", div(n, 2) - 1) end |> String.to_integer IO.puts x end end