"use strict";

function Main(input) {
  input = input.split('\n');
  var c500 = Number(input[0]);
  var c100 = Number(input[1]);
  var c50 = Number(input[2]);
  var sum = Number(input[3]);
  var ans = 0;

  for (var a = 0; a <= c500; a++) {
    for (var b = 0; b <= c100; b++) {
      for (var c = 0; c <= c50; c++) {
        if (a * 500 + b * 100 + c * 50 == sum) ans++;
      }
    }
  }

  console.log(ans);
}

Main(require("fs").readFileSync("/dev/stdin", "utf8"));