import java.io.*;

public class Main {
    public static void main(String[] agrs) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int n = Integer.parseInt(br.readLine());
        int five = 0;
        
        for(int i=2; i<=n; i++) {
            int temp = i;
            while(temp%5==0) {
                five++;
                temp = temp/5;
            }
        }
        
        System.out.println(five);
    }
}