function Main(input) {
  input = input.trim()
  input = input.split(" ").map(Number);
  function compareFunc(a, b) {
  return a - b;
}
input.sort(compareFunc);
    console.log(input[2]*input[1])
}Main(require("fs").readFileSync("/dev/stdin", "utf8"));
