import java.util.Scanner;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);

    int yen500 = sc.nextInt();
    int yen100 = sc.nextInt();
    int yen50 = sc.nextInt();
    int total = sc.nextInt();
    
    sc.close();

    int count = 0;

    for (int i = 0; i <= yen500; i++) {
      for (int j = 0; j <= yen100; j++) {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            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 yen500 = sc.nextInt();
    int yen100 = sc.nextInt();
    int yen50 = sc.nextInt();
    int total = sc.nextInt();
    
    sc.close();

    int count = 0;

    for (int i = 0; i <= yen500; i++) {
      for (int j = 0; j <= yen100; j++) {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        }
      }   
    }

    System.out.println(count);
  
  }
} Main public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);

    int yen500 = sc.nextInt();
    int yen100 = sc.nextInt();
    int yen50 = sc.nextInt();
    int total = sc.nextInt();
    
    sc.close();

    int count = 0;

    for (int i = 0; i <= yen500; i++) {
      for (int j = 0; j <= yen100; j++) {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        }
      }   
    }

    System.out.println(count);
  
  } main {
    Scanner sc = new Scanner(System.in);

    int yen500 = sc.nextInt();
    int yen100 = sc.nextInt();
    int yen50 = sc.nextInt();
    int total = sc.nextInt();
    
    sc.close();

    int count = 0;

    for (int i = 0; i <= yen500; i++) {
      for (int j = 0; j <= yen100; j++) {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        }
      }   
    }

    System.out.println(count);
  
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int yen500 = sc.nextInt(); yen500 sc.nextInt() sc.nextInt sc int yen100 = sc.nextInt(); yen100 sc.nextInt() sc.nextInt sc int yen50 = sc.nextInt(); yen50 sc.nextInt() sc.nextInt sc int total = sc.nextInt(); total sc.nextInt() sc.nextInt sc sc.close() sc.close sc int count = 0; count 0 for (int i = 0; i <= yen500; i++) {
      for (int j = 0; j <= yen100; j++) {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        }
      }   
    } int i = 0; int i = 0; i 0 i <= yen500 i yen500 i++ i++ i {
      for (int j = 0; j <= yen100; j++) {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        }
      }   
    } {
      for (int j = 0; j <= yen100; j++) {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        }
      }   
    } for (int j = 0; j <= yen100; j++) {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        }
      } int j = 0; int j = 0; j 0 j <= yen100 j yen100 j++ j++ j {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        }
      } {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        }
      } for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        } int k = 0; int k = 0; k 0 k <= yen50 k yen50 k++ k++ k {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        } {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        } if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          } total == (i * 500 + j * 100 + k * 50) total (i * 500 + j * 100 + k * 50) i * 500 + j * 100 + k * 50 i * 500 i 500 j * 100 j 100 k * 50 k 50 {
            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 yen500 = sc.nextInt();
    int yen100 = sc.nextInt();
    int yen50 = sc.nextInt();
    int total = sc.nextInt();
    
    sc.close();

    int count = 0;

    for (int i = 0; i <= yen500; i++) {
      for (int j = 0; j <= yen100; j++) {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        }
      }   
    }

    System.out.println(count);
  
  }
} public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);

    int yen500 = sc.nextInt();
    int yen100 = sc.nextInt();
    int yen50 = sc.nextInt();
    int total = sc.nextInt();
    
    sc.close();

    int count = 0;

    for (int i = 0; i <= yen500; i++) {
      for (int j = 0; j <= yen100; j++) {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            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 yen500 = sc.nextInt();
    int yen100 = sc.nextInt();
    int yen50 = sc.nextInt();
    int total = sc.nextInt();
    
    sc.close();

    int count = 0;

    for (int i = 0; i <= yen500; i++) {
      for (int j = 0; j <= yen100; j++) {
        for (int k = 0; k <= yen50; k++) {
          if (total == (i * 500 + j * 100 + k * 50)) {
            count++;
          }
        }
      }   
    }

    System.out.println(count);
  
  }
}