#include <bits/stdc++.h>
using namespace std;
#define ll long long int
class problem
{
  public:
    int gcd(long long a,long long b)
    {
      if(a==0)
      {
        return b;
      }
      return gcd(b%a,a);
    }
    int lcm(long long a,long long b)
    {
      return (a*b)/gcd(a,b);
    }
    int fibo(int n)
    {
      double a;
      a=(1+sqrt(5))/2;
      return round(pow(a,n)/sqrt(5));
    }
   void sive(long long n)
    {
      long long i,j,count=0;
      bool ar[n];
      memset(ar,true,sizeof(ar));
      for(i=2;i*i<=n;i++)
      {
        if(ar[i]==true)
        {
          for(j=i*i;j<=n;j=j+i)
          {
            ar[j]=false;
          }
        }
      }
      cout<<"Prime Number between 1 to"<<n<<endl;
     for(i=2;i<=n;i++)
      {
        if(ar[i]==true)
        {
          cout<<i<<" ";
        }
      }
    }
    void segment(long long a,long long b)
    {
      long long n,i,base,j;
      bool ar[b-a+1];
      bool isprime [b-a+1];
      for(i=0;i<b-a+1;i++)
      {
        isprime[i]=true;
      }
      if(a==1)isprime[0]=false;
      memset(ar,true,sizeof(ar));
        for(i=2;i*i<=b;i++)
        {
          if(ar[i])
          {
            for(j=i*i;j<=b;j=j+i)
            {
              ar[j]=false;
            }
          }
        }
        for(i=2;i*i<=(b);i++)
        {
          if(ar[i])
          {
             base=i*i;
             if(base<a)
             {
               base=((a+i-1)/i)*i;
             }
             for(j=base;j<=b-a+1;j=j+i)
             {
               isprime[j-a]=false;
             }
          }
        }
        
        for(i=0;i<b-a+1;i++)
        {
         
          if(isprime[i]==true)
          {
            cout<<a+i<<" ";
          }
          j++;
        }
    }
    void bigfactorial(int n)
    {
      int ar[5000],i;
      ar[0]=1;
      int sizee=1;
      for(i=2;i<=n;i++)
      {
        sizee=multiple(i,ar,sizee);
      }
      cout<<"Factorial of your Number"<<endl;
      for(i=sizee-1;i>=0;i--)
      {
        cout<<ar[i];
      }
      cout<<endl;
    }
    int multiple(int x,int ar[],int sizee)
    {
      int carry=0,tem,i;
      for(i=0;i<sizee;i++)
      {
        tem=ar[i]*x+carry;
        ar[i]=tem%10;
        carry=tem/10;
      }
      while(carry!=0)
      {
        ar[sizee]=carry%10;
        carry=carry/10;
        sizee++;
      }
      return sizee;
    }
    bool check(int n,int i)
    {
      if(n&(1<<i))
      {
        return true;
      }
      else
      {
        return false;
      }
    }
    int bs(vector<int>vec,int low,int high,int v)
    {
      int mid=(low+high)/2;
      while(1)
      {
        if(v>=vec[mid-1]&&v<=vec[mid])
        {
          return mid+1;
        }
        else if(vec[mid]>v)
        {
          high=mid;
        }
        else if(vec[mid]<v)
        {
          low=mid;
        }
        mid=(low+high)/2;
      }
      
    }
    int sum(int n)
    {
      if(n>0){
        cout<<n<<" ";
        sum(n-1);
        cout<<"a"<<" ";
        sum(n-1);
      }
      
    }
    ll product(ll a,ll b,ll x,ll y,ll n)
    {
      ll tem1,tem2;
      tem1=min(n,a-x);
      tem2=min(n-tem1,b-y);
      return (a-tem1)*(b-tem2);
    }
   int summ(int n)
   {
     int tem,t,sum=0;
     while(n!=0)
     {
       t=n%10;
       sum=sum+t;
       n=n/10;
     }
    return sum;
   }
    void solve()
    {
    
      long long n,i,a,b,c,y,a1,a2,a3,a4,x,d;
      cin>>a>>b>>c>>d;
      a1=a*c;
      a2=a*d;
      a3=b*c;
      a4=b*d;
      x=max(a1,a2);
      y=max(a3,a4);
      cout<<max(x,y);
    }
};
int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    problem codeforces;
  /*int tc;
    cin>>tc;
    while(tc--)
    {
      codeforces.solve();
    }*/
  codeforces.solve();
 //  cout<<codeforces.sum(3);
    return 0;
}

Measured memory_bytes: 3624