A = int(eval(input()))

B = int(eval(input()))

C = int(eval(input()))

X = int(eval(input()))



ans = 0



for i in range(A+1):

    for j in range(B+1):

        for k in range(C+1):

            temp = i * 500 + j * 100 + k * 50

            if temp == X:

                ans += 1



print(ans)

# -*- coding: utf-8 -*-



A = int(eval(input()))

B = int(eval(input()))

C = int(eval(input()))

X = int(eval(input()))





def solve(a, b, c):

    ans = 0

    for i in range(a+1):

        for j in range(b+1):

            for k in range(c+1):

                temp = i * 500 + j * 100 + k * 50

                if temp == X:

                    ans += 1

    return ans





def main():

    ans = solve(A, B, C)

    print(ans)





if __name__ == '__main__':

    main()

A = int(eval(input()))
B = int(eval(input()))
C = int(eval(input()))
X = int(eval(input()))
ans = 0
for i in range(A + 1):
    for j in range(B + 1):
        for k in range(C + 1):
            temp = i * 500 + j * 100 + k * 50
            if temp == X:
                ans += 1
print(ans)

# -*- coding: utf-8 -*-
A = int(eval(input()))
B = int(eval(input()))
C = int(eval(input()))
X = int(eval(input()))


def solve(a, b, c):
    ans = 0
    for i in range(a + 1):
        for j in range(b + 1):
            for k in range(c + 1):
                temp = i * 500 + j * 100 + k * 50
                if temp == X:
                    ans += 1
    return ans


def main():
    ans = solve(A, B, C)
    print(ans)


if __name__ == "__main__":
    main()

+# -*- coding: utf-8 -*- -ans = 0 -for i in range(A + 1): -    for j in range(B + 1): -        for k in range(C + 1): -            temp = i * 500 + j * 100 + k * 50 -            if temp == X: -                ans += 1 -print(ans) + + +def solve(a, b, c): +    ans = 0 +    for i in range(a + 1): +        for j in range(b + 1): +            for k in range(c + 1): +                temp = i * 500 + j * 100 + k * 50 +                if temp == X: +                    ans += 1 +    return ans + + +def main(): +    ans = solve(A, B, C) +    print(ans) + + +if __name__ == "__main__": +    main()