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 result = 0;

		for (int fiveHundreds = a ; fiveHundreds >= 0 ; fiveHundreds--) {
			int remaining = x - fiveHundreds * 500;
			if (remaining >= 0) {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			}
		}
		System.out.println(result);
	}
} 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 result = 0;

		for (int fiveHundreds = a ; fiveHundreds >= 0 ; fiveHundreds--) {
			int remaining = x - fiveHundreds * 500;
			if (remaining >= 0) {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			}
		}
		System.out.println(result);
	}
} 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 result = 0;

		for (int fiveHundreds = a ; fiveHundreds >= 0 ; fiveHundreds--) {
			int remaining = x - fiveHundreds * 500;
			if (remaining >= 0) {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			}
		}
		System.out.println(result);
	} main {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		int c = sc.nextInt();
		int x = sc.nextInt();
  
		int result = 0;

		for (int fiveHundreds = a ; fiveHundreds >= 0 ; fiveHundreds--) {
			int remaining = x - fiveHundreds * 500;
			if (remaining >= 0) {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			}
		}
		System.out.println(result);
	} 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 result = 0; result 0 for (int fiveHundreds = a ; fiveHundreds >= 0 ; fiveHundreds--) {
			int remaining = x - fiveHundreds * 500;
			if (remaining >= 0) {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			}
		} int fiveHundreds = a ; int fiveHundreds = a ; fiveHundreds a fiveHundreds >= 0 fiveHundreds 0 fiveHundreds-- fiveHundreds-- fiveHundreds {
			int remaining = x - fiveHundreds * 500;
			if (remaining >= 0) {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			}
		} {
			int remaining = x - fiveHundreds * 500;
			if (remaining >= 0) {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			}
		} int remaining = x - fiveHundreds * 500; remaining x - fiveHundreds * 500 x fiveHundreds * 500 fiveHundreds 500 if (remaining >= 0) {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			} remaining >= 0 remaining 0 {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			} for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				} int oneHundreds = b ; int oneHundreds = b ; oneHundreds b oneHundreds >= 0 oneHundreds 0 oneHundreds-- oneHundreds-- oneHundreds {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				} {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				} int remaining2 = remaining - oneHundreds * 100; remaining2 remaining - oneHundreds * 100 remaining oneHundreds * 100 oneHundreds 100 if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					} remaining2 >= 0 remaining2 0 {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					} for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						} int fifties = c ; int fifties = c ; fifties c fifties >= 0 fifties 0 fifties-- fifties-- fifties {
							if (remaining2 == fifties * 50) {
								result++;
							}
						} {
							if (remaining2 == fifties * 50) {
								result++;
							}
						} if (remaining2 == fifties * 50) {
								result++;
							} remaining2 == fifties * 50 remaining2 fifties * 50 fifties 50 {
								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) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		int c = sc.nextInt();
		int x = sc.nextInt();
  
		int result = 0;

		for (int fiveHundreds = a ; fiveHundreds >= 0 ; fiveHundreds--) {
			int remaining = x - fiveHundreds * 500;
			if (remaining >= 0) {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			}
		}
		System.out.println(result);
	}
} 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 result = 0;

		for (int fiveHundreds = a ; fiveHundreds >= 0 ; fiveHundreds--) {
			int remaining = x - fiveHundreds * 500;
			if (remaining >= 0) {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			}
		}
		System.out.println(result);
	}
} 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 result = 0;

		for (int fiveHundreds = a ; fiveHundreds >= 0 ; fiveHundreds--) {
			int remaining = x - fiveHundreds * 500;
			if (remaining >= 0) {
				for (int oneHundreds = b ; oneHundreds >= 0 ; oneHundreds--) {
					int remaining2 = remaining - oneHundreds * 100;
					if (remaining2 >= 0) {
						for (int fifties = c ; fifties >= 0 ; fifties--) {
							if (remaining2 == fifties * 50) {
								result++;
							}
						}
					}
				}
			}
		}
		System.out.println(result);
	}
}
