import java.util.Scanner;

public class Main {

	public static void main(String[] args){
		// TODO ABC_087_B
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
	    // Scannerクラスのインスタンスをクローズ
		sc.close();

		int ret = 0;
		int sumA = 0, sumB = 0, sumC = 0;
		int maiA = 0, maiB = 0, maiC = 0;

		for(maiA = 0; maiA <= A; maiA++) {
			if(maiA * 500 > X) {
				break;
			}
			sumA = maiA * 500;

			for(maiB = 0; maiB <= B; maiB++) {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			}
		}

		// 出力
		System.out.println(ret);

	}
} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args){
		// TODO ABC_087_B
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
	    // Scannerクラスのインスタンスをクローズ
		sc.close();

		int ret = 0;
		int sumA = 0, sumB = 0, sumC = 0;
		int maiA = 0, maiB = 0, maiC = 0;

		for(maiA = 0; maiA <= A; maiA++) {
			if(maiA * 500 > X) {
				break;
			}
			sumA = maiA * 500;

			for(maiB = 0; maiB <= B; maiB++) {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			}
		}

		// 出力
		System.out.println(ret);

	}
} Main public static void main(String[] args){
		// TODO ABC_087_B
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
	    // Scannerクラスのインスタンスをクローズ
		sc.close();

		int ret = 0;
		int sumA = 0, sumB = 0, sumC = 0;
		int maiA = 0, maiB = 0, maiC = 0;

		for(maiA = 0; maiA <= A; maiA++) {
			if(maiA * 500 > X) {
				break;
			}
			sumA = maiA * 500;

			for(maiB = 0; maiB <= B; maiB++) {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			}
		}

		// 出力
		System.out.println(ret);

	} main {
		// TODO ABC_087_B
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
	    // Scannerクラスのインスタンスをクローズ
		sc.close();

		int ret = 0;
		int sumA = 0, sumB = 0, sumC = 0;
		int maiA = 0, maiB = 0, maiC = 0;

		for(maiA = 0; maiA <= A; maiA++) {
			if(maiA * 500 > X) {
				break;
			}
			sumA = maiA * 500;

			for(maiB = 0; maiB <= B; maiB++) {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			}
		}

		// 出力
		System.out.println(ret);

	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int A = sc.nextInt(); A sc.nextInt() sc.nextInt sc int B = sc.nextInt(); B sc.nextInt() sc.nextInt sc int C = sc.nextInt(); C sc.nextInt() sc.nextInt sc int X = sc.nextInt(); X sc.nextInt() sc.nextInt sc sc.close() sc.close sc int ret = 0; ret 0 int sumA = 0 sumA 0 sumB = 0 sumB 0 sumC = 0; sumC 0 int maiA = 0 maiA 0 maiB = 0 maiB 0 maiC = 0; maiC 0 for(maiA = 0; maiA <= A; maiA++) {
			if(maiA * 500 > X) {
				break;
			}
			sumA = maiA * 500;

			for(maiB = 0; maiB <= B; maiB++) {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			}
		} maiA = 0; maiA = 0 maiA 0 maiA <= A maiA A maiA++ maiA++ maiA {
			if(maiA * 500 > X) {
				break;
			}
			sumA = maiA * 500;

			for(maiB = 0; maiB <= B; maiB++) {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			}
		} {
			if(maiA * 500 > X) {
				break;
			}
			sumA = maiA * 500;

			for(maiB = 0; maiB <= B; maiB++) {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			}
		} if(maiA * 500 > X) {
				break;
			} maiA * 500 > X maiA * 500 maiA 500 X {
				break;
			} break; sumA = maiA * 500 sumA maiA * 500 maiA 500 for(maiB = 0; maiB <= B; maiB++) {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			} maiB = 0; maiB = 0 maiB 0 maiB <= B maiB B maiB++ maiB++ maiB {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			} {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			} if(maiB * 100 + sumA > X) {
					break;
				} maiB * 100 + sumA > X maiB * 100 + sumA maiB * 100 maiB 100 sumA X {
					break;
				} break; sumB = maiB * 100 + sumA sumB maiB * 100 + sumA maiB * 100 maiB 100 sumA for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				} maiC = 0; maiC = 0 maiC 0 maiC <= C maiC C maiC++ maiC++ maiC {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				} {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				} if(maiC * 50 + sumB > X) {
						break;
					} maiC * 50 + sumB > X maiC * 50 + sumB maiC * 50 maiC 50 sumB X {
						break;
					} break; sumC = maiC * 50 + sumB sumC maiC * 50 + sumB maiC * 50 maiC 50 sumB if(sumC == X) {
						ret++;
						break;
					} sumC == X sumC X {
						ret++;
						break;
					} ret++ ret break; System.out.println(ret) System.out.println System.out System System.out ret String[] args args public class Main {

	public static void main(String[] args){
		// TODO ABC_087_B
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
	    // Scannerクラスのインスタンスをクローズ
		sc.close();

		int ret = 0;
		int sumA = 0, sumB = 0, sumC = 0;
		int maiA = 0, maiB = 0, maiC = 0;

		for(maiA = 0; maiA <= A; maiA++) {
			if(maiA * 500 > X) {
				break;
			}
			sumA = maiA * 500;

			for(maiB = 0; maiB <= B; maiB++) {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			}
		}

		// 出力
		System.out.println(ret);

	}
} public class Main {

	public static void main(String[] args){
		// TODO ABC_087_B
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
	    // Scannerクラスのインスタンスをクローズ
		sc.close();

		int ret = 0;
		int sumA = 0, sumB = 0, sumC = 0;
		int maiA = 0, maiB = 0, maiC = 0;

		for(maiA = 0; maiA <= A; maiA++) {
			if(maiA * 500 > X) {
				break;
			}
			sumA = maiA * 500;

			for(maiB = 0; maiB <= B; maiB++) {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			}
		}

		// 出力
		System.out.println(ret);

	}
} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args){
		// TODO ABC_087_B
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
	    // Scannerクラスのインスタンスをクローズ
		sc.close();

		int ret = 0;
		int sumA = 0, sumB = 0, sumC = 0;
		int maiA = 0, maiB = 0, maiC = 0;

		for(maiA = 0; maiA <= A; maiA++) {
			if(maiA * 500 > X) {
				break;
			}
			sumA = maiA * 500;

			for(maiB = 0; maiB <= B; maiB++) {
				if(maiB * 100 + sumA > X) {
					break;
				}
				sumB = maiB * 100 + sumA;

				for(maiC = 0; maiC <= C; maiC++) {
					if(maiC * 50 + sumB > X) {
						break;
					}
					sumC = maiC * 50 + sumB;
					if(sumC == X) {
						ret++;
						break;
					}
				}
			}
		}

		// 出力
		System.out.println(ret);

	}
}
