#include <iostream>
using namespace std;
int main(){
long long a,b,c,d,e,kutiq=0;
cin>>a>>b>>c>>d>>e;
swap(a,c);
swap(b,d);
long long obsto=a*a*a+b*b*b+c*c*c+d*d*d;
if(a+b<=e && a+c<=e && obsto<=e*e*e)
{
    cout<<1;
}
else
{
    if(obsto>e*e*e)
    {
        if(obsto%(e*e*e)==0)
        cout<<obsto/(e*e*e);
        else{
                if(a+b<=e && a+c<=e)
              cout<<obsto/(e*e*e)+1;
              else
                 cout<<obsto/(e*e*e)+2;
        }
    }
    else
        if((e*e*e)>=obsto)
    {
        if((e*e*e)%obsto==0)
            cout<<(e*e*e)/obsto;
        else
            if(a+b<=e && a+c<=e)
            cout<<(e*e*e)/obsto+1;
        else
            cout<<(e*e*e)/obsto+2;
    }
}
return 0;
}
