#include<iostream>
#include<cstdio>
using namespace std;
int main()
{
	int a,b,c,x,i,j,l,ans=0;
	cin>>a>>b>>c>>x;
	for(i=0;i<=a;i++)
		for(j=0;j<=b;j++)
			for(l=0;l<=c;l++)
				if(500*i+100*j+50*l==x) ans++;
	cout<<ans<<endl;
	return 0;
}