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