defmodule Main do
  def main do
    IO.gets("")
    |> String.trim()
    |> String.to_integer()
    |> process()
    |> IO.puts()
  end
  
  defp process(n) when n < 15, do: n * 800
  defp process(n), do: n * 800 - div(n,15) * 200
end