import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		Integer a = Integer.valueOf(br.readLine());
		Integer b = Integer.valueOf(br.readLine());
		Integer c = Integer.valueOf(br.readLine());
		Integer x = Integer.valueOf(br.readLine());
		int result = 0;
		for(int i=0;i<=a;i++) {
			for(int j=0;j<=b;j++) {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			}
		}
		System.out.println(result);
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		Integer a = Integer.valueOf(br.readLine());
		Integer b = Integer.valueOf(br.readLine());
		Integer c = Integer.valueOf(br.readLine());
		Integer x = Integer.valueOf(br.readLine());
		int result = 0;
		for(int i=0;i<=a;i++) {
			for(int j=0;j<=b;j++) {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			}
		}
		System.out.println(result);
	}
} Main public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		Integer a = Integer.valueOf(br.readLine());
		Integer b = Integer.valueOf(br.readLine());
		Integer c = Integer.valueOf(br.readLine());
		Integer x = Integer.valueOf(br.readLine());
		int result = 0;
		for(int i=0;i<=a;i++) {
			for(int j=0;j<=b;j++) {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			}
		}
		System.out.println(result);
	} main {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		Integer a = Integer.valueOf(br.readLine());
		Integer b = Integer.valueOf(br.readLine());
		Integer c = Integer.valueOf(br.readLine());
		Integer x = Integer.valueOf(br.readLine());
		int result = 0;
		for(int i=0;i<=a;i++) {
			for(int j=0;j<=b;j++) {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			}
		}
		System.out.println(result);
	} BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) Integer a = Integer.valueOf(br.readLine()); a Integer.valueOf(br.readLine()) Integer.valueOf Integer br.readLine() br.readLine br Integer b = Integer.valueOf(br.readLine()); b Integer.valueOf(br.readLine()) Integer.valueOf Integer br.readLine() br.readLine br Integer c = Integer.valueOf(br.readLine()); c Integer.valueOf(br.readLine()) Integer.valueOf Integer br.readLine() br.readLine br Integer x = Integer.valueOf(br.readLine()); x Integer.valueOf(br.readLine()) Integer.valueOf Integer br.readLine() br.readLine br int result = 0; result 0 for(int i=0;i<=a;i++) {
			for(int j=0;j<=b;j++) {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			}
		} int i=0; int i=0; i 0 i<=a i a i++ i++ i {
			for(int j=0;j<=b;j++) {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			}
		} {
			for(int j=0;j<=b;j++) {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			}
		} for(int j=0;j<=b;j++) {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			} int j=0; int j=0; j 0 j<=b j b j++ j++ j {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			} {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			} int rest = x - 500 * i - 100 * j; rest x - 500 * i - 100 * j x - 500 * i - 100 * j x 500 * i 500 i 100 * j 100 j if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++; rest >= 0 && rest % 50 == 0 && rest / 50 <= c rest >= 0 && rest % 50 == 0 && rest / 50 <= c rest >= 0 rest 0 rest % 50 == 0 rest % 50 rest 50 0 rest / 50 <= c rest / 50 rest 50 c result++ result System.out.println(result) System.out.println System.out System System.out result String[] args args public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		Integer a = Integer.valueOf(br.readLine());
		Integer b = Integer.valueOf(br.readLine());
		Integer c = Integer.valueOf(br.readLine());
		Integer x = Integer.valueOf(br.readLine());
		int result = 0;
		for(int i=0;i<=a;i++) {
			for(int j=0;j<=b;j++) {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			}
		}
		System.out.println(result);
	}
} public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		Integer a = Integer.valueOf(br.readLine());
		Integer b = Integer.valueOf(br.readLine());
		Integer c = Integer.valueOf(br.readLine());
		Integer x = Integer.valueOf(br.readLine());
		int result = 0;
		for(int i=0;i<=a;i++) {
			for(int j=0;j<=b;j++) {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			}
		}
		System.out.println(result);
	}
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		Integer a = Integer.valueOf(br.readLine());
		Integer b = Integer.valueOf(br.readLine());
		Integer c = Integer.valueOf(br.readLine());
		Integer x = Integer.valueOf(br.readLine());
		int result = 0;
		for(int i=0;i<=a;i++) {
			for(int j=0;j<=b;j++) {
				int rest = x - 500 * i - 100 * j;
				if(rest >= 0 && rest % 50 == 0 && rest / 50 <= c) result++;
			}
		}
		System.out.println(result);
	}
}