N = int(eval(input()))



ans = 0



if N % 2 == 0:

    mod = 10

    while N >= mod:

        ans += N // mod

        mod *= 5



print(ans)

# def f(n):

#     if n < 2:

#         return 1

#     else:

#         return n * f(n - 2)



# for i in range(2, 150, 2):

#     print(i, f(i))



N = int(eval(input()))



if N % 2 == 1:

    print((0))

    exit()



k = 10

cnt = 0

while k <= N:

    cnt += N // k

    k *= 5



print(cnt)

N = int(eval(input()))
ans = 0
if N % 2 == 0:
    mod = 10
    while N >= mod:
        ans += N // mod
        mod *= 5
print(ans)

# def f(n):
#     if n < 2:
#         return 1
#     else:
#         return n * f(n - 2)
# for i in range(2, 150, 2):
#     print(i, f(i))
N = int(eval(input()))
if N % 2 == 1:
    print((0))
    exit()
k = 10
cnt = 0
while k <= N:
    cnt += N // k
    k *= 5
print(cnt)

+# def f(n): +#     if n < 2: +#         return 1 +#     else: +#         return n * f(n - 2) +# for i in range(2, 150, 2): +#     print(i, f(i)) -ans = 0 -if N % 2 == 0: -    mod = 10 -    while N >= mod: -        ans += N // mod -        mod *= 5 -print(ans) +if N % 2 == 1: +    print((0)) +    exit() +k = 10 +cnt = 0 +while k <= N: +    cnt += N // k +    k *= 5 +print(cnt)