import 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();
		
		sc.close();
		
		int res = 0;
				
		for (int a = 0; a <= A ; a++) {
			
			for (int b = 0 ; b <= B ; b++) {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			}
			
		}
		
		System.out.println(res);
			
	}	


} import java.util.*; util.* java 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();
		
		sc.close();
		
		int res = 0;
				
		for (int a = 0; a <= A ; a++) {
			
			for (int b = 0 ; b <= B ; b++) {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			}
			
		}
		
		System.out.println(res);
			
	}	


} 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();
		
		sc.close();
		
		int res = 0;
				
		for (int a = 0; a <= A ; a++) {
			
			for (int b = 0 ; b <= B ; b++) {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			}
			
		}
		
		System.out.println(res);
			
	} main {

		
		Scanner sc = new Scanner(System.in);
		
		int A = sc.nextInt();
		int B = sc.nextInt();
		int C = sc.nextInt();
		int X = sc.nextInt();
		
		sc.close();
		
		int res = 0;
				
		for (int a = 0; a <= A ; a++) {
			
			for (int b = 0 ; b <= B ; b++) {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			}
			
		}
		
		System.out.println(res);
			
	} 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 res = 0; res 0 for (int a = 0; a <= A ; a++) {
			
			for (int b = 0 ; b <= B ; b++) {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			}
			
		} int a = 0; int a = 0; a 0 a <= A a A a++ a++ a {
			
			for (int b = 0 ; b <= B ; b++) {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			}
			
		} {
			
			for (int b = 0 ; b <= B ; b++) {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			}
			
		} for (int b = 0 ; b <= B ; b++) {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			} int b = 0 ; int b = 0 ; b 0 b <= B b B b++ b++ b {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			} {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			} for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				} int c = 0 ; int c = 0 ; c 0 c <= C c C c ++ c ++ c {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				} {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				} int total = 500*a + 100*b + 50*c; total 500*a + 100*b + 50*c 500*a + 100*b + 50*c 500*a 500 a 100*b 100 b 50*c 50 c if (total == X) res++; total == X total X res++ res System.out.println(res) System.out.println System.out System System.out res 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();
		
		sc.close();
		
		int res = 0;
				
		for (int a = 0; a <= A ; a++) {
			
			for (int b = 0 ; b <= B ; b++) {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			}
			
		}
		
		System.out.println(res);
			
	}	


} 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();
		
		sc.close();
		
		int res = 0;
				
		for (int a = 0; a <= A ; a++) {
			
			for (int b = 0 ; b <= B ; b++) {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			}
			
		}
		
		System.out.println(res);
			
	}	


} Main
import 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();
		
		sc.close();
		
		int res = 0;
				
		for (int a = 0; a <= A ; a++) {
			
			for (int b = 0 ; b <= B ; b++) {
				
				for (int c = 0 ; c <= C ; c ++ ) {
					
					int total = 500*a + 100*b + 50*c;
					
					if (total == X) res++;
				}
			}
			
		}
		
		System.out.println(res);
			
	}	


}