//// Abhishek Jha  ////

#include<bits/stdc++.h>
#define ll long long int
#define pb push_back
#define fi first
#define se second
#define ss string
#define ll long long int
#define Endl endl
#define aaste long long int n,i;cin>>n;long long int a[n];for(i=0;i<n;i++)cin>>a[i];
#define u_b upper_bound
#define rep(i,n)         for(int i=0;i<n;i++)
#define ld long double
#define tc long long t;cin>>t;while(t--)
#define fr(i,a,b)        for(long long int i=a;i<=b;i++)
#define E endl
#define FIO ios_base::sync_with_stdio(false);cin.tie(NULL);
#define V deque<ll>v;
const ll   mod=            1000000007;
const ll   MOD1=           (int)1e9 + 9;
const ll   MOD2=           998244353;
const ld    pi=             atan2(0, -1);
const ld    eps=            1e-9;
const int   N=                   2e5+5;
 
const int MAXR = 1000005;
ll         tests=          1;
 
using namespace std;
struct custom_hash {
    static uint64_t splitmix64(uint64_t x) {
        x += 0x9e3779b97f4a7c15;
        x = (x ^ (x >> 30)) * 0xbf58476d1ce4e5b9;
        x = (x ^ (x >> 27)) * 0x94d049bb133111eb;
        return x ^ (x >> 31);
    }

    size_t operator()(uint64_t x) const {
        static const uint64_t FIXED_RANDOM = chrono::steady_clock::now().time_since_epoch().count();
        return splitmix64(x + FIXED_RANDOM);
    }
};
ll binarySearch(ll l, ll r,ll k)
{
  if (r >= l) {
    ll mid = l + (r - l) / 2;
    if (mid*(mid+1)==k)
      return 1;
    if (mid*(mid+1)>k)
      return binarySearch( l, mid - 1,k);
    return binarySearch(mid + 1, r, k);
  }
  return 0;
}
bool sortinrev(const pair<int,int> &a,  
               const pair<int,int> &b) 
{ 
       return (a.first > b.first); 
} 
void swap(ll *p1, ll *p2)
{
   ll temp=*p1;
   *p1=*p2;
   *p2=temp;
}
int MaxSubArraySumReturn(int a[], int  n) //negative thakle o kaaj korbe in O(n)
{
 
    int sum = 0, best = 0;
   for(ll i=0;i<n;i++)
    {
        sum = max(a[i], a[i] + sum);
        best = max(best, sum);
    }
    return best;
}
ll totalDigits(ll n) 
{ 
 
    ll number_of_digits = 0; 
    for (ll i = 1; i <= n; i *= 10) 
        number_of_digits += (n - i + 1); 
  
    return number_of_digits; 
  }
int CeilIndex(std::vector<int>& v, int l, int r, int key) 
{ 
    while (r - l > 1) { 
        int m = l + (r - l) / 2; 
        if (v[m] >= key) 
            r = m; 
        else
            l = m; 
    } 
  
    return r; 
} 
  
int LongestIncreasingSubsequenceLength(std::vector<int>& v,int p) 
{ 
    if (v.size() == 0) 
        return 0; 
  
    std::vector<int> tail(v.size(), 0); 
    int length = 1;
    tail[0] = v[0]; 
    for (size_t i = 1; i < v.size(); i++) { 
        if (v[i] < tail[0]) 
            tail[0] = v[i]; 
        else if (v[i] > tail[length - 1]) 
            tail[length++] = v[i]; 
        else
            tail[CeilIndex(tail, -1, length - 1, v[i])] = v[i]; 
    } 
  
    return (p-length); 
}
ll getPairsCount(ll arr[], ll n, ll sum) 
{ 
    int count = 0; // Initialize result 
    map<int,int>mp;
    // Consider all possible pairs and check their sums 
    for (int i=0; i<n; i++)
    {
        for (int j=i+1; j<n; j++) 
        {
            if (mp[i]==0 && mp[j]==0 && arr[i]+arr[j] == sum) 
            {
                mp[i]=1;
                mp[j]=1;
                count++; 
            }
        }
    }
    mp.clear();
    return count; 
}
// SOME OF THE FUNCTIONS HERE ARE TAKEN FROM GEEKS FOR GEEKS
//PLEASE DONT CONSIDER THEM FOR PLAGARISM
ll pow(ll x,ll y,ll p)  
{  
    ll mama=1;
    x = x % p;
    if (x == 0) return 0;
    while (y > 0)  
    {  
        if (y%2==1)  
          mama = (mama*x) % p; 
        y = y>>1;  
        x = (x*x) % p;  
    } 
    return mama;
}
ll maxnikalo(ll a[],ll n)
{
  ll maxi=a[0];
  for(ll i=0;i<n;i++)
  {
    maxi=max(maxi,a[i]);
  }
  return maxi;
}
ll freqofelm(ll a[],ll ele,ll n)
{
  ll ctr=0;
  for(ll i=0;i<n;i++)
  {
   if(a[i]==ele)
    ctr++;
  }
  return ctr;
}
// taken from gfg
unsigned long long modI(unsigned long long n, int p) 
{ 
    return pow(n, p - 2, p); 
} 
// taken from gfg
unsigned long long nCr(unsigned long long n, 
                              int r, int p) 
{ 
    if (r == 0) 
        return 1; 
    unsigned long long factor[n + 1]; 
    factor[0] = 1; 
    for (ll i = 1; i <= n; i++) 
        factor[i] = (factor[i - 1] * i) % p; 
    return (factor[n] * modI(factor[r], p) % p * modI(factor[n - r], p) % p) % p; 
} 
int main()
{
  FIO
  #ifndef ONLINE_JUDGE
    {
        freopen("input.txt", "r", stdin);
        freopen("output.txt", "w", stdout);
        freopen("error.txt", "w", stderr);
    }
#endif
   ll a,b,c,d;
   cin>>a>>b>>c>>d;
   
   
    ll maxi=max(a*d,b*c);
    maxi=max(maxi,a*c);
    maxi=max(maxi,b*d);
     cout<<maxi;
   
   
}

Measured memory_bytes: 3652