function Main(input) {
  input = input.split('\n')

  const c500 = Number(input[0])
  const c100 = Number(input[1])
  const c50 = Number(input[2])
  const sum = Number(input[3])

  let ans = 0

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

  console.log(ans)
}

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