import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		try(Scanner sc = new Scanner(System.in)){
			int fiveHundred = sc.nextInt();
			int hundred = sc.nextInt();
			int five = sc.nextInt();
			int x = sc.nextInt();
			int result = 0;
			for (int i = 0 ; i <= fiveHundred; i++) {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			}
			System.out.println(result);
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		try(Scanner sc = new Scanner(System.in)){
			int fiveHundred = sc.nextInt();
			int hundred = sc.nextInt();
			int five = sc.nextInt();
			int x = sc.nextInt();
			int result = 0;
			for (int i = 0 ; i <= fiveHundred; i++) {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			}
			System.out.println(result);
		}
	}
} Main public static void main(String[] args) {
		try(Scanner sc = new Scanner(System.in)){
			int fiveHundred = sc.nextInt();
			int hundred = sc.nextInt();
			int five = sc.nextInt();
			int x = sc.nextInt();
			int result = 0;
			for (int i = 0 ; i <= fiveHundred; i++) {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			}
			System.out.println(result);
		}
	} main {
		try(Scanner sc = new Scanner(System.in)){
			int fiveHundred = sc.nextInt();
			int hundred = sc.nextInt();
			int five = sc.nextInt();
			int x = sc.nextInt();
			int result = 0;
			for (int i = 0 ; i <= fiveHundred; i++) {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			}
			System.out.println(result);
		}
	} try(Scanner sc = new Scanner(System.in)){
			int fiveHundred = sc.nextInt();
			int hundred = sc.nextInt();
			int five = sc.nextInt();
			int x = sc.nextInt();
			int result = 0;
			for (int i = 0 ; i <= fiveHundred; i++) {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			}
			System.out.println(result);
		} {
			int fiveHundred = sc.nextInt();
			int hundred = sc.nextInt();
			int five = sc.nextInt();
			int x = sc.nextInt();
			int result = 0;
			for (int i = 0 ; i <= fiveHundred; i++) {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			}
			System.out.println(result);
		} Scanner sc = new Scanner(System.in) Scanner sc = new Scanner(System.in) new Scanner(System.in) int fiveHundred = sc.nextInt(); fiveHundred sc.nextInt() sc.nextInt sc int hundred = sc.nextInt(); hundred sc.nextInt() sc.nextInt sc int five = sc.nextInt(); five sc.nextInt() sc.nextInt sc int x = sc.nextInt(); x sc.nextInt() sc.nextInt sc int result = 0; result 0 for (int i = 0 ; i <= fiveHundred; i++) {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			} int i = 0 ; int i = 0 ; i 0 i <= fiveHundred i fiveHundred i++ i++ i {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			} {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			} for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				} int j = 0 ; int j = 0 ; j 0 j <= hundred j hundred j++ j++ j {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				} {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				} for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					} int k=0; int k=0; k 0 k <=five k five k++ k++ k {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					} {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					} if(i*500+j*100+50*k == x) {
							result++;
						} i*500+j*100+50*k == x i*500+j*100+50*k i*500+j*100+50*k i*500 i 500 j*100 j 100 50*k 50 k x {
							result++;
						} 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) {
		try(Scanner sc = new Scanner(System.in)){
			int fiveHundred = sc.nextInt();
			int hundred = sc.nextInt();
			int five = sc.nextInt();
			int x = sc.nextInt();
			int result = 0;
			for (int i = 0 ; i <= fiveHundred; i++) {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			}
			System.out.println(result);
		}
	}
} public class Main {
	public static void main(String[] args) {
		try(Scanner sc = new Scanner(System.in)){
			int fiveHundred = sc.nextInt();
			int hundred = sc.nextInt();
			int five = sc.nextInt();
			int x = sc.nextInt();
			int result = 0;
			for (int i = 0 ; i <= fiveHundred; i++) {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			}
			System.out.println(result);
		}
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		try(Scanner sc = new Scanner(System.in)){
			int fiveHundred = sc.nextInt();
			int hundred = sc.nextInt();
			int five = sc.nextInt();
			int x = sc.nextInt();
			int result = 0;
			for (int i = 0 ; i <= fiveHundred; i++) {
				for (int j = 0 ; j <= hundred ; j++) {
					for (int k=0; k <=five; k++) {
						if(i*500+j*100+50*k == x) {
							result++;
						}
					}
				}
			}
			System.out.println(result);
		}
	}
}