#include <bits/stdc++.h>
using namespace std;

int main(){
    int64_t N; cin >> N;
    int64_t ans = 0;
    if(N & 1) ans = 0;
    else{
        N >>= 1; 
        while(N) { ans += N/5; N /= 5;}
    }

    cout << ans << endl;
}