defmodule Main do def main do IO.read(:line) |> String.trim() |> String.to_integer() |> solve |> IO.puts() end def solve(i) do 1..i |> Enum.join() |> String.to_charlist |> Enum.at(i - 1) |> (&([&1])).() end end