defmodule Main do
  def main do
    IO.gets("")
    |> String.trim()
    |> String.split()
    |> Enum.map(&String.to_integer/1)
    |> process()
    |> IO.puts()
  end
  
  def process([a, b, c, d]) when a * b == c * d, do: a * b
  def process([a, b, c, d]) when a * b > c * d, do: a * b
  def process([_, _, c, d]), do: c * d 
end