#include<cstdio>
#define re register
#define int long long
using namespace std;
int n,a,b,c,d;
signed main(){
scanf("%lld",&n);
if(n&1)puts("0");
else{
for(re int i=5;i<=n;i*=5){
	b+=n/(i*2);
}
printf("%lld",b);}
}
