import java.util.Arrays;
import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        long a = nextInt(scanner);
        long b = nextInt(scanner);
        long c = nextInt(scanner);
        long d = nextInt(scanner);
        System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
    }

    private static int nextInt(Scanner scanner) {
        return Integer.parseInt(scanner.next());
    }

    private static long nextLong(Scanner scanner) {
        return Long.parseLong(scanner.next());
    }

    private static float nextFloat(Scanner scanner) {
        return Float.parseFloat(scanner.next());
    }

    private static double nextDouble(Scanner scanner) {
        return Double.parseDouble(scanner.next());
    }


}


class UnionFind {
    int[] parent;

    UnionFind(int n) {
        parent = new int[n];
        Arrays.fill(parent, -1);
    }

    int find(int x) {
        if (parent[x] < 0) {
            return x;
        } else {
            parent[x] = find(parent[x]);
            return parent[x];
        }
    }

    void unite(int x, int y) {
        int rootX = find(x);
        int rootY = find(y);
        if (rootX == rootY) {
            return;
        }

        if (parent[rootX] > parent[rootY]) {
            int temp = rootX;
            rootX = rootY;
            rootY = temp;
        }
        parent[rootX] += parent[rootY];
        parent[rootY] = rootX;
    }

} import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util public class Main {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        long a = nextInt(scanner);
        long b = nextInt(scanner);
        long c = nextInt(scanner);
        long d = nextInt(scanner);
        System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
    }

    private static int nextInt(Scanner scanner) {
        return Integer.parseInt(scanner.next());
    }

    private static long nextLong(Scanner scanner) {
        return Long.parseLong(scanner.next());
    }

    private static float nextFloat(Scanner scanner) {
        return Float.parseFloat(scanner.next());
    }

    private static double nextDouble(Scanner scanner) {
        return Double.parseDouble(scanner.next());
    }


} Main public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        long a = nextInt(scanner);
        long b = nextInt(scanner);
        long c = nextInt(scanner);
        long d = nextInt(scanner);
        System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
    } main {
        Scanner scanner = new Scanner(System.in);
        long a = nextInt(scanner);
        long b = nextInt(scanner);
        long c = nextInt(scanner);
        long d = nextInt(scanner);
        System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) long a = nextInt(scanner); a nextInt(scanner) nextInt scanner long b = nextInt(scanner); b nextInt(scanner) nextInt scanner long c = nextInt(scanner); c nextInt(scanner) nextInt scanner long d = nextInt(scanner); d nextInt(scanner) nextInt scanner System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d)))) System.out.println System.out System System.out Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))) Math.max Math a * c a c Math.max(a * d, Math.max(b * c, b * d)) Math.max Math a * d a d Math.max(b * c, b * d) Math.max Math b * c b c b * d b d String[] args args private static int nextInt(Scanner scanner) {
        return Integer.parseInt(scanner.next());
    } nextInt {
        return Integer.parseInt(scanner.next());
    } return Integer.parseInt(scanner.next()); Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner Scanner scanner scanner private static long nextLong(Scanner scanner) {
        return Long.parseLong(scanner.next());
    } nextLong {
        return Long.parseLong(scanner.next());
    } return Long.parseLong(scanner.next()); Long.parseLong(scanner.next()) Long.parseLong Long scanner.next() scanner.next scanner Scanner scanner scanner private static float nextFloat(Scanner scanner) {
        return Float.parseFloat(scanner.next());
    } nextFloat {
        return Float.parseFloat(scanner.next());
    } return Float.parseFloat(scanner.next()); Float.parseFloat(scanner.next()) Float.parseFloat Float scanner.next() scanner.next scanner Scanner scanner scanner private static double nextDouble(Scanner scanner) {
        return Double.parseDouble(scanner.next());
    } nextDouble {
        return Double.parseDouble(scanner.next());
    } return Double.parseDouble(scanner.next()); Double.parseDouble(scanner.next()) Double.parseDouble Double scanner.next() scanner.next scanner Scanner scanner scanner class UnionFind {
    int[] parent;

    UnionFind(int n) {
        parent = new int[n];
        Arrays.fill(parent, -1);
    }

    int find(int x) {
        if (parent[x] < 0) {
            return x;
        } else {
            parent[x] = find(parent[x]);
            return parent[x];
        }
    }

    void unite(int x, int y) {
        int rootX = find(x);
        int rootY = find(y);
        if (rootX == rootY) {
            return;
        }

        if (parent[rootX] > parent[rootY]) {
            int temp = rootX;
            rootX = rootY;
            rootY = temp;
        }
        parent[rootX] += parent[rootY];
        parent[rootY] = rootX;
    }

} UnionFind int[] parent; parent UnionFind(int n) {
        parent = new int[n];
        Arrays.fill(parent, -1);
    } UnionFind {
        parent = new int[n];
        Arrays.fill(parent, -1);
    } parent = new int[n] parent new int[n] n Arrays.fill(parent, -1) Arrays.fill Arrays parent -1 1 int n n int find(int x) {
        if (parent[x] < 0) {
            return x;
        } else {
            parent[x] = find(parent[x]);
            return parent[x];
        }
    } find {
        if (parent[x] < 0) {
            return x;
        } else {
            parent[x] = find(parent[x]);
            return parent[x];
        }
    } if (parent[x] < 0) {
            return x;
        } else {
            parent[x] = find(parent[x]);
            return parent[x];
        } parent[x] < 0 parent[x] parent x 0 {
            return x;
        } return x; x {
            parent[x] = find(parent[x]);
            return parent[x];
        } parent[x] = find(parent[x]) parent[x] parent x find(parent[x]) find parent[x] parent x return parent[x]; parent[x] parent x int x x void unite(int x, int y) {
        int rootX = find(x);
        int rootY = find(y);
        if (rootX == rootY) {
            return;
        }

        if (parent[rootX] > parent[rootY]) {
            int temp = rootX;
            rootX = rootY;
            rootY = temp;
        }
        parent[rootX] += parent[rootY];
        parent[rootY] = rootX;
    } unite {
        int rootX = find(x);
        int rootY = find(y);
        if (rootX == rootY) {
            return;
        }

        if (parent[rootX] > parent[rootY]) {
            int temp = rootX;
            rootX = rootY;
            rootY = temp;
        }
        parent[rootX] += parent[rootY];
        parent[rootY] = rootX;
    } int rootX = find(x); rootX find(x) find x int rootY = find(y); rootY find(y) find y if (rootX == rootY) {
            return;
        } rootX == rootY rootX rootY {
            return;
        } return; if (parent[rootX] > parent[rootY]) {
            int temp = rootX;
            rootX = rootY;
            rootY = temp;
        } parent[rootX] > parent[rootY] parent[rootX] parent rootX parent[rootY] parent rootY {
            int temp = rootX;
            rootX = rootY;
            rootY = temp;
        } int temp = rootX; temp rootX rootX = rootY rootX rootY rootY = temp rootY temp parent[rootX] += parent[rootY] parent[rootX] parent rootX parent[rootY] parent rootY parent[rootY] = rootX parent[rootY] parent rootY rootX int x x int y y public class Main {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        long a = nextInt(scanner);
        long b = nextInt(scanner);
        long c = nextInt(scanner);
        long d = nextInt(scanner);
        System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
    }

    private static int nextInt(Scanner scanner) {
        return Integer.parseInt(scanner.next());
    }

    private static long nextLong(Scanner scanner) {
        return Long.parseLong(scanner.next());
    }

    private static float nextFloat(Scanner scanner) {
        return Float.parseFloat(scanner.next());
    }

    private static double nextDouble(Scanner scanner) {
        return Double.parseDouble(scanner.next());
    }


} public class Main {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        long a = nextInt(scanner);
        long b = nextInt(scanner);
        long c = nextInt(scanner);
        long d = nextInt(scanner);
        System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
    }

    private static int nextInt(Scanner scanner) {
        return Integer.parseInt(scanner.next());
    }

    private static long nextLong(Scanner scanner) {
        return Long.parseLong(scanner.next());
    }

    private static float nextFloat(Scanner scanner) {
        return Float.parseFloat(scanner.next());
    }

    private static double nextDouble(Scanner scanner) {
        return Double.parseDouble(scanner.next());
    }


} Main
import java.util.Arrays;
import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        long a = nextInt(scanner);
        long b = nextInt(scanner);
        long c = nextInt(scanner);
        long d = nextInt(scanner);
        System.out.println(Math.max(a * c, Math.max(a * d, Math.max(b * c, b * d))));
    }

    private static int nextInt(Scanner scanner) {
        return Integer.parseInt(scanner.next());
    }

    private static long nextLong(Scanner scanner) {
        return Long.parseLong(scanner.next());
    }

    private static float nextFloat(Scanner scanner) {
        return Float.parseFloat(scanner.next());
    }

    private static double nextDouble(Scanner scanner) {
        return Double.parseDouble(scanner.next());
    }


}


class UnionFind {
    int[] parent;

    UnionFind(int n) {
        parent = new int[n];
        Arrays.fill(parent, -1);
    }

    int find(int x) {
        if (parent[x] < 0) {
            return x;
        } else {
            parent[x] = find(parent[x]);
            return parent[x];
        }
    }

    void unite(int x, int y) {
        int rootX = find(x);
        int rootY = find(y);
        if (rootX == rootY) {
            return;
        }

        if (parent[rootX] > parent[rootY]) {
            int temp = rootX;
            rootX = rootY;
            rootY = temp;
        }
        parent[rootX] += parent[rootY];
        parent[rootY] = rootX;
    }

}
