"use strict";

function main(input) {
  input = input.trim().split(" ");
  const a = Number(input[0]);
  const b = Number(input[1]);
  const c = Number(input[2]);
  const d = Number(input[3]);

  let ans;
  ans = a * c;
  if (ans < a * d) {
    ans = a * d;
  }
  if (ans < b * c) {
    ans = b * c;
  }
  if (ans < b * d) {
    ans = b * d;
  }
  console.log(ans);
}

function numberSort(array) {
  array.sort(f);
  return array;
}

var f = function (a, b) {
  return a - b;
};

main(require("fs").readFileSync("/dev/stdin", "utf-8"));
