a, b, c, d = gets.strip.split.map(&:to_i)

if a <= 0 && b >= 0 && c <= 0 && d >= 0
  if a * c < b * d
    puts b * d
  else
    puts a * c
  end
elsif b >= 0 && c <= 0
  puts a * d
elsif b <= 0 && c >= 0
  puts b * c
else
  if a * c > b * d
    puts a * c
  else
    puts b * d
  end
end
