import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int count = 0;
		int[] coin = new int[3];
		for(int i = 0; i < 3; i++) {
			coin[i] = sc.nextInt();
		}
		int x = sc.nextInt();
		for(int t = 0; t <= coin[0]; t++) {
			for(int j = 0; j <= coin[1]; j++) {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			}
		}
		System.out.println(count);
	}
} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int count = 0;
		int[] coin = new int[3];
		for(int i = 0; i < 3; i++) {
			coin[i] = sc.nextInt();
		}
		int x = sc.nextInt();
		for(int t = 0; t <= coin[0]; t++) {
			for(int j = 0; j <= coin[1]; j++) {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			}
		}
		System.out.println(count);
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int count = 0;
		int[] coin = new int[3];
		for(int i = 0; i < 3; i++) {
			coin[i] = sc.nextInt();
		}
		int x = sc.nextInt();
		for(int t = 0; t <= coin[0]; t++) {
			for(int j = 0; j <= coin[1]; j++) {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			}
		}
		System.out.println(count);
	} main {
		Scanner sc = new Scanner(System.in);
		int count = 0;
		int[] coin = new int[3];
		for(int i = 0; i < 3; i++) {
			coin[i] = sc.nextInt();
		}
		int x = sc.nextInt();
		for(int t = 0; t <= coin[0]; t++) {
			for(int j = 0; j <= coin[1]; j++) {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			}
		}
		System.out.println(count);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int count = 0; count 0 int[] coin = new int[3]; coin new int[3] 3 for(int i = 0; i < 3; i++) {
			coin[i] = sc.nextInt();
		} int i = 0; int i = 0; i 0 i < 3 i 3 i++ i++ i {
			coin[i] = sc.nextInt();
		} {
			coin[i] = sc.nextInt();
		} coin[i] = sc.nextInt() coin[i] coin i sc.nextInt() sc.nextInt sc int x = sc.nextInt(); x sc.nextInt() sc.nextInt sc for(int t = 0; t <= coin[0]; t++) {
			for(int j = 0; j <= coin[1]; j++) {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			}
		} int t = 0; int t = 0; t 0 t <= coin[0] t coin[0] coin 0 t++ t++ t {
			for(int j = 0; j <= coin[1]; j++) {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			}
		} {
			for(int j = 0; j <= coin[1]; j++) {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			}
		} for(int j = 0; j <= coin[1]; j++) {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			} int j = 0; int j = 0; j 0 j <= coin[1] j coin[1] coin 1 j++ j++ j {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			} {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			} for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				} int k = 0; int k = 0; k 0 k <= coin[2] k coin[2] coin 2 k++ k++ k {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				} {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				} int sum = 500 * t + 100 * j + 50 * k; sum 500 * t + 100 * j + 50 * k 500 * t + 100 * j + 50 * k 500 * t 500 t 100 * j 100 j 50 * k 50 k if(sum == x) {
						count++;
					} sum == x sum x {
						count++;
					} count++ count System.out.println(count) System.out.println System.out System System.out count String[] args args public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int count = 0;
		int[] coin = new int[3];
		for(int i = 0; i < 3; i++) {
			coin[i] = sc.nextInt();
		}
		int x = sc.nextInt();
		for(int t = 0; t <= coin[0]; t++) {
			for(int j = 0; j <= coin[1]; j++) {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			}
		}
		System.out.println(count);
	}
} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int count = 0;
		int[] coin = new int[3];
		for(int i = 0; i < 3; i++) {
			coin[i] = sc.nextInt();
		}
		int x = sc.nextInt();
		for(int t = 0; t <= coin[0]; t++) {
			for(int j = 0; j <= coin[1]; j++) {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			}
		}
		System.out.println(count);
	}
} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int count = 0;
		int[] coin = new int[3];
		for(int i = 0; i < 3; i++) {
			coin[i] = sc.nextInt();
		}
		int x = sc.nextInt();
		for(int t = 0; t <= coin[0]; t++) {
			for(int j = 0; j <= coin[1]; j++) {
				for(int k = 0; k <= coin[2]; k++) {
					int sum = 500 * t + 100 * j + 50 * k;
					if(sum == x) {
						count++;
					}
				}
			}
		}
		System.out.println(count);
	}
}