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.lang.System;
import java.util.*;

public class Solution {
    public static void main(String[] args){
        final Scanner in = new Scanner(System.in);
        final int max = in.nextInt();
        final int n = max + 1;
        final List<Integer> primes = new ArrayList<Integer>();
        final boolean[] array = new boolean[n];  
        for(int i = 2; i < n; i++){
            if(array[i]) continue;
            primes.add(i);
            for(int j = i; j < n; j+=i){
                array[j] = true;
            }
        }      
        
        final Set<Integer> result = new HashSet<Integer>();
        for(Integer i : primes){
            for(Integer j : primes) {
                if(i != j){
                    result.addAll(getCombinations(i, j, max));
                }
            }
        }
        System.out.println(result.size());
    }
    
    public static Collection<Integer> getCombinations(int a, int b, int max){
        final Set<Integer> result = new HashSet<Integer>();
        for(int i = 1; Math.pow(a, i) < max; ++i){
            for(int j = 1; Math.pow(b, j) < max; ++j){
                double tmp = Math.pow(a, i) * Math.pow(b, j);
                if(tmp <= max) {
                    result.add((int)tmp);
                }
            }
        }
        return result;
    }
}