N = int(eval(input()))

ans=0



if N%2==1:

    print(ans)

else:

    for i in range(1,40):

            a = 2*pow(5,i)

            ans+=(N//a)

    print(ans)
import sys

input = sys.stdin.readline



def I(): return int(eval(input()))

def MI(): return list(map(int, input().split()))

def LI(): return list(map(int, input().split()))



def main():

    mod=10**9+7

    N=I()

    if N%2==1:

        print((0))

        exit()

    

    ans=0

    

    for i in range(1,100):

        a=2*pow(5,i)

        ans+=N//a

        

    print(ans)

        

    

    



main()

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

import sys

input = sys.stdin.readline


def I():
    return int(eval(input()))


def MI():
    return list(map(int, input().split()))


def LI():
    return list(map(int, input().split()))


def main():
    mod = 10**9 + 7
    N = I()
    if N % 2 == 1:
        print((0))
        exit()
    ans = 0
    for i in range(1, 100):
        a = 2 * pow(5, i)
        ans += N // a
    print(ans)


main()

-N = int(eval(input())) -ans = 0 -if N % 2 == 1: -    print(ans) -else: -    for i in range(1, 40): +import sys + +input = sys.stdin.readline + + +def I(): +    return int(eval(input())) + + +def MI(): +    return list(map(int, input().split())) + + +def LI(): +    return list(map(int, input().split())) + + +def main(): +    mod = 10**9 + 7 +    N = I() +    if N % 2 == 1: +        print((0)) +        exit() +    ans = 0 +    for i in range(1, 100): + + +main()