#include <iostream>
#include <stdlib.h>
#include <math.h>
#include <vector> 

using namespace std;
int main(int argc, char** argv)
{
	int r,p,q,a,b,c,br;
	long int l,n;
	br=0;
	cin>>p>>q>>r>>l>>n;
	for (l;l<=n;l++)
	{
		a=ceil((float)l/p);
		b=ceil((float)l/q);
		c=ceil((float)l/r);
		//if (l%p==0)
		//{a=l/p;}
		//if (l%q ==0)
		//{b=l/q;}
		//if (l%r ==0)
		//{c=l/r;}		
		if((a+b+c)<=l)
		br++;
		
	}
	cout<<br;
	return 0;
}