import java.util.*;

class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int a = Integer.parseInt(scanner.nextLine());
        int b = Integer.parseInt(scanner.nextLine());
        int c = Integer.parseInt(scanner.nextLine());
        int x = Integer.parseInt(scanner.nextLine());

        int result = 0;
        for (int i500 = 0; i500 <= a; i500++) {
            for (int i100 = 0; i100 <= b; i100++) {
                int rest = (x - 500 * i500 - 100 * i100);
                if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                }
            }
        }
        System.out.println(result);
    }
} import java.util.*; util.* java class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int a = Integer.parseInt(scanner.nextLine());
        int b = Integer.parseInt(scanner.nextLine());
        int c = Integer.parseInt(scanner.nextLine());
        int x = Integer.parseInt(scanner.nextLine());

        int result = 0;
        for (int i500 = 0; i500 <= a; i500++) {
            for (int i100 = 0; i100 <= b; i100++) {
                int rest = (x - 500 * i500 - 100 * i100);
                if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                }
            }
        }
        System.out.println(result);
    }
} Main public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int a = Integer.parseInt(scanner.nextLine());
        int b = Integer.parseInt(scanner.nextLine());
        int c = Integer.parseInt(scanner.nextLine());
        int x = Integer.parseInt(scanner.nextLine());

        int result = 0;
        for (int i500 = 0; i500 <= a; i500++) {
            for (int i100 = 0; i100 <= b; i100++) {
                int rest = (x - 500 * i500 - 100 * i100);
                if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                }
            }
        }
        System.out.println(result);
    } main {
        Scanner scanner = new Scanner(System.in);
        int a = Integer.parseInt(scanner.nextLine());
        int b = Integer.parseInt(scanner.nextLine());
        int c = Integer.parseInt(scanner.nextLine());
        int x = Integer.parseInt(scanner.nextLine());

        int result = 0;
        for (int i500 = 0; i500 <= a; i500++) {
            for (int i100 = 0; i100 <= b; i100++) {
                int rest = (x - 500 * i500 - 100 * i100);
                if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                }
            }
        }
        System.out.println(result);
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int a = Integer.parseInt(scanner.nextLine()); a Integer.parseInt(scanner.nextLine()) Integer.parseInt Integer scanner.nextLine() scanner.nextLine scanner int b = Integer.parseInt(scanner.nextLine()); b Integer.parseInt(scanner.nextLine()) Integer.parseInt Integer scanner.nextLine() scanner.nextLine scanner int c = Integer.parseInt(scanner.nextLine()); c Integer.parseInt(scanner.nextLine()) Integer.parseInt Integer scanner.nextLine() scanner.nextLine scanner int x = Integer.parseInt(scanner.nextLine()); x Integer.parseInt(scanner.nextLine()) Integer.parseInt Integer scanner.nextLine() scanner.nextLine scanner int result = 0; result 0 for (int i500 = 0; i500 <= a; i500++) {
            for (int i100 = 0; i100 <= b; i100++) {
                int rest = (x - 500 * i500 - 100 * i100);
                if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                }
            }
        } int i500 = 0; int i500 = 0; i500 0 i500 <= a i500 a i500++ i500++ i500 {
            for (int i100 = 0; i100 <= b; i100++) {
                int rest = (x - 500 * i500 - 100 * i100);
                if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                }
            }
        } {
            for (int i100 = 0; i100 <= b; i100++) {
                int rest = (x - 500 * i500 - 100 * i100);
                if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                }
            }
        } for (int i100 = 0; i100 <= b; i100++) {
                int rest = (x - 500 * i500 - 100 * i100);
                if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                }
            } int i100 = 0; int i100 = 0; i100 0 i100 <= b i100 b i100++ i100++ i100 {
                int rest = (x - 500 * i500 - 100 * i100);
                if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                }
            } {
                int rest = (x - 500 * i500 - 100 * i100);
                if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                }
            } int rest = (x - 500 * i500 - 100 * i100); rest (x - 500 * i500 - 100 * i100) x - 500 * i500 - 100 * i100 x 500 * i500 500 i500 100 * i100 100 i100 if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                } rest >= 0 && rest == Math.min(rest / 50, c) * 50 rest >= 0 rest 0 rest == Math.min(rest / 50, c) * 50 rest Math.min(rest / 50, c) * 50 Math.min(rest / 50, c) Math.min Math rest / 50 rest 50 c 50 {
                    result++;
                } result++ result System.out.println(result) System.out.println System.out System System.out result String[] args args
import java.util.*;

class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int a = Integer.parseInt(scanner.nextLine());
        int b = Integer.parseInt(scanner.nextLine());
        int c = Integer.parseInt(scanner.nextLine());
        int x = Integer.parseInt(scanner.nextLine());

        int result = 0;
        for (int i500 = 0; i500 <= a; i500++) {
            for (int i100 = 0; i100 <= b; i100++) {
                int rest = (x - 500 * i500 - 100 * i100);
                if (rest >= 0 && rest == Math.min(rest / 50, c) * 50) {
                    result++;
                }
            }
        }
        System.out.println(result);
    }
}
