
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        String x = sc.nextLine();
        String[] data = x.split(" ");
        List<BigDecimal> dataDecimalList = new ArrayList();
        for(String a: data){
            BigDecimal bd = new BigDecimal(a);
            dataDecimalList.add(bd);
        }
        List<BigDecimal> targetList = new ArrayList();
        targetList.add(dataDecimalList.get(0).multiply(dataDecimalList.get(2)));
        targetList.add(dataDecimalList.get(0).multiply(dataDecimalList.get(3)));
        targetList.add(dataDecimalList.get(1).multiply(dataDecimalList.get(2)));
        targetList.add(dataDecimalList.get(1).multiply(dataDecimalList.get(3)));

        BigDecimal max = new BigDecimal("-1000000000000000000000000000000000000000000000000000000000000000000000000000");
        for(BigDecimal target: targetList){
            if(max.compareTo(target) == -1){
                max = target;
            }
        }
        System.out.println(max);
    }
}

/tmp/hf-datasets-cache/medium/datasets/42704881117311-config-parquet-and-info-qiankunmu-Project_CodeNet-896c9d36/hub/datasets--qiankunmu--Project_CodeNet_Python800_and_Java250/snapshots/c899fde44a77ba1cc14973ed3de064e4ff3aadc7/Project_CodeNet_Java250.tar.gz