#include <bits/stdc++.h>
using namespace std;

int main()
{
    int a, b, c, d;
    cin >> a >> b >> c >> d;
    int num_m = a * c;
    int num;
    num = a * d;
    if (num_m < num)
    {
        num_m = num;
    }
    num = b * c;
    if (num_m < num)
    {
        num_m = num;
    }
    num = b * d;
    if (num_m < num)
    {
        num_m = num;
    }
    cout << num_m << endl;
}