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.text.ParseException;
import java.util.*;
import java.io.*;
import java.math.BigInteger;


import static java.lang.Math.*;

    public class solver {
    
 
    final boolean ONLINE_JUDGE = System.getProperty("ONLINE_JUDGE")!=null;
    
    BufferedReader in;
    static PrintWriter out;
    StringTokenizer tok = new StringTokenizer("");
    
    void init() throws FileNotFoundException{
        if (ONLINE_JUDGE){          
             in = new BufferedReader(new InputStreamReader(System.in));
             out = new PrintWriter(System.out);    
             
        }else{  
            in = new BufferedReader(new FileReader("input.txt"));
            out = new PrintWriter("output.txt");           
        }
    }
    
    String readString() throws IOException{
        while(!tok.hasMoreTokens()){
            try{
                tok = new StringTokenizer(in.readLine());
            }catch (Exception e){               
                return null;
            }
        }
        return tok.nextToken();
    }
    
    int readInt() throws IOException{
        return Integer.parseInt(readString());
    }
    
    long readLong() throws IOException{
        return Long.parseLong(readString());
    }
    
    double readDouble() throws IOException{
        return Double.parseDouble(readString());
    }
    
    public static void main(String[] args) throws IOException, ParseException{       
        new solver().run();
    }
    
    long timeBegin, timeEnd;

    void time(){
        timeEnd = System.currentTimeMillis();
        System.err.println("Time = " + (timeEnd - timeBegin));
    }
    int[] iMas(int n) throws IOException{
        int[] a=new int[n];
        for (int i=0;i<n;i++){
            a[i]=readInt();
        }
        return a;
    }
    void oMas(int[] a){
        for (int i=0;i<a.length;i++){
            out.println(a[i]);
        }
    }
    
    int gcd(int a,int b){
        if (b==0) return a;
        return gcd(b, a%b);
    }
    
    
    
    
    
    
    
    
    void solve() throws IOException{
        int n=readInt();
        int[] a=new int[n+1];
        
        boolean[] prime=new boolean[n+1];
        Arrays.fill(prime, true);
        prime[0]=prime[1]=false;
        
        for (int i=2;i<=n;i++){
            if (!prime[i]) continue;
            for (int j=6;j<=n;j++){
                if (j%i==0) a[j]++;
            }
            int j=i*i;
            while (j<=n){
                prime[j]=false;
                j+=i;
            }
        }
        int answer=0;
        for (int i=1;i<=n;i++) {                    
            answer+=(a[i]==2)?1:0;
        }
        out.println(answer);
        
        
        
        
    }
    
    public void run() throws IOException, ParseException{
        
        init(); 
        long h=System.currentTimeMillis();
        solve();        
        System.err.println(System.currentTimeMillis()-h);
        out.close();
    }
    
    
}