defmodule Main do def main do 1..2 |> Enum.map(fn _ -> IO.read(:line) |> String.trim() |> String.to_charlist() |> Enum.sort() end) |> solve |> IO.puts() end defp solve([a, b]) do cond do a == b -> "YES" true -> "NO" end end end