import java.util.Scanner;

public class Main {

	public static void main(String[] args) {

		Scanner sc = new Scanner(System.in);

		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
		int cnt = 0;

		for (int i = 0; i < C + 1; i++) {

			int Y = X - 50 * i;

			if(Y == 0) {
				cnt ++;
				continue;
			}

			for (int j = 0; j < B + 1; j++) {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			}
		}
		System.out.println(cnt);
	}
} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {

		Scanner sc = new Scanner(System.in);

		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
		int cnt = 0;

		for (int i = 0; i < C + 1; i++) {

			int Y = X - 50 * i;

			if(Y == 0) {
				cnt ++;
				continue;
			}

			for (int j = 0; j < B + 1; j++) {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			}
		}
		System.out.println(cnt);
	}
} Main public static void main(String[] args) {

		Scanner sc = new Scanner(System.in);

		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
		int cnt = 0;

		for (int i = 0; i < C + 1; i++) {

			int Y = X - 50 * i;

			if(Y == 0) {
				cnt ++;
				continue;
			}

			for (int j = 0; j < B + 1; j++) {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			}
		}
		System.out.println(cnt);
	} main {

		Scanner sc = new Scanner(System.in);

		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
		int cnt = 0;

		for (int i = 0; i < C + 1; i++) {

			int Y = X - 50 * i;

			if(Y == 0) {
				cnt ++;
				continue;
			}

			for (int j = 0; j < B + 1; j++) {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			}
		}
		System.out.println(cnt);
	} 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 int cnt = 0; cnt 0 for (int i = 0; i < C + 1; i++) {

			int Y = X - 50 * i;

			if(Y == 0) {
				cnt ++;
				continue;
			}

			for (int j = 0; j < B + 1; j++) {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			}
		} int i = 0; int i = 0; i 0 i < C + 1 i C + 1 C 1 i++ i++ i {

			int Y = X - 50 * i;

			if(Y == 0) {
				cnt ++;
				continue;
			}

			for (int j = 0; j < B + 1; j++) {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			}
		} {

			int Y = X - 50 * i;

			if(Y == 0) {
				cnt ++;
				continue;
			}

			for (int j = 0; j < B + 1; j++) {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			}
		} int Y = X - 50 * i; Y X - 50 * i X 50 * i 50 i if(Y == 0) {
				cnt ++;
				continue;
			} Y == 0 Y 0 {
				cnt ++;
				continue;
			} cnt ++ cnt continue; for (int j = 0; j < B + 1; j++) {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			} int j = 0; int j = 0; j 0 j < B + 1 j B + 1 B 1 j++ j++ j {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			} {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			} int Z = Y - 100 * j; Z Y - 100 * j Y 100 * j 100 j if(Z == 0) {
					cnt++;
					continue;
				} Z == 0 Z 0 {
					cnt++;
					continue;
				} cnt++ cnt continue; for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				} int k = 0; int k = 0; k 0 k < A + 1 k A + 1 A 1 k++ k++ k {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				} {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				} int W = Z - 500 * k; W Z - 500 * k Z 500 * k 500 k if(W == 0) {
						cnt ++;
						continue;
					} W == 0 W 0 {
						cnt ++;
						continue;
					} cnt ++ cnt continue; System.out.println(cnt) System.out.println System.out System System.out cnt String[] args args public class Main {

	public static void main(String[] args) {

		Scanner sc = new Scanner(System.in);

		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
		int cnt = 0;

		for (int i = 0; i < C + 1; i++) {

			int Y = X - 50 * i;

			if(Y == 0) {
				cnt ++;
				continue;
			}

			for (int j = 0; j < B + 1; j++) {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			}
		}
		System.out.println(cnt);
	}
} public class Main {

	public static void main(String[] args) {

		Scanner sc = new Scanner(System.in);

		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
		int cnt = 0;

		for (int i = 0; i < C + 1; i++) {

			int Y = X - 50 * i;

			if(Y == 0) {
				cnt ++;
				continue;
			}

			for (int j = 0; j < B + 1; j++) {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			}
		}
		System.out.println(cnt);
	}
} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {

		Scanner sc = new Scanner(System.in);

		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
		int cnt = 0;

		for (int i = 0; i < C + 1; i++) {

			int Y = X - 50 * i;

			if(Y == 0) {
				cnt ++;
				continue;
			}

			for (int j = 0; j < B + 1; j++) {

				int Z = Y - 100 * j;

				if(Z == 0) {
					cnt++;
					continue;
				}

				for (int k = 0; k < A + 1; k++) {

					int W = Z - 500 * k;

					if(W == 0) {
						cnt ++;
						continue;
					}
				}
			}
		}
		System.out.println(cnt);
	}
}
