A number is called almost prime if it has exactly two distinct prime divisors. For example, numbers 6, 18, 24 are almost prime, while 4, 8, 9, 42 are not. Find the amount of almost prime numbers which are between 1 and n, inclusive.

Input

Input contains one integer number n (1 ≤ n ≤ 3000).

Output

Output the amount of almost prime numbers between 1 and n, inclusive.

Examples

Input

10


Output

2


Input

21


Output

8

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Arrays;

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author publica
 */
public class A {
    public static void main(String[]arg) throws IOException{
        new A().read();
    }
    
    public void read() throws IOException{
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        int n;
        n = Integer.parseInt(in.readLine());
        System.out.println(cntPrimes(n));
    }
    
    int cntPrimes(int n){
        int cnt = 0,i,j;
        int[]cntPrimes = new int[n+1];
        boolean[]notIsPrime = new boolean[n+1];
        int[]memo = new int[n+1];
        for(i = 2; i <= n ;i++){
            if(!notIsPrime[i]){
                for(j = i+i; j <= n ; j+=i){
                    cntPrimes[j]++;
                    notIsPrime[j] = true;
                }
            }
        }
        
        for(i = 2; i <= n; i++){
            if(cntPrimes[i] == 2) cnt++;
        }
        return cnt;
    }
}
