n=int(eval(input()))

if n%2!=0:

  print((0))

else:

  a=0

  for i in range(1,26):

    a+=(n//(2*5**i))

  print(a)
n=int(eval(input()))

ans=0

if n%2==1:

  print((0))

else:

  n=n//2

  for i in range(1,50):

    ans+=(n//(5**i))

  print((int(ans)))
n = int(eval(input()))
if n % 2 != 0:
    print((0))
else:
    a = 0
    for i in range(1, 26):
        a += n // (2 * 5**i)
    print(a)

n = int(eval(input()))
ans = 0
if n % 2 == 1:
    print((0))
else:
    n = n // 2
    for i in range(1, 50):
        ans += n // (5**i)
    print((int(ans)))

-if n % 2 != 0: +ans = 0 +if n % 2 == 1: -    a = 0 -    for i in range(1, 26): -        a += n // (2 * 5**i) -    print(a) +    n = n // 2 +    for i in range(1, 50): +        ans += n // (5**i) +    print((int(ans)))