function MainB(input){
    const [a,b,c,d] = input.split(' ').map(BigInt);
    let answer = 0;
    const ac = a*c;
    const ad = a*d;
    const bc = b*c;
    const bd = b*d;
    // log({ac,ad,bc,bd})
    const acVSbc = ac > bc ? ac : bc;
    const adVSbd = ad > bd ? ad : bd;
    // log({acVSbc, adVSbd});
    console.log(acVSbc > adVSbd ? String(acVSbc).split('n')[0] : String(adVSbd).split('n')[0]);
}
MainB(require("fs").readFileSync("/dev/stdin", "utf8").trim());
