#include <bits/stdc++.h>
using namespace std;
const long long inf = 1e18 + 7;
const long long N = 1e6 + 7;
const long long md = 1e9 + 7;
long long tz(long long n) {
  long long cnt = 0;
  for (long long i = 5; n / i >= 1; i *= 5) cnt += n / (i);
  return cnt;
}
void sol() {
  long long n;
  cin >> n;
  if (n % 2) {
    cout << 0;
    return;
  }
  n /= 2;
  cout << tz(n);
}
int32_t main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long T = 1;
  sol();
  return 0;
}
