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.util.*;
public class A26 {
	
	public static int a[] = new int[3000];
	public static int la = 0;
	
	public static boolean isap(int x){
		int cnt = 0;
		for(int i = 0 ; i<la;i++){
			if (x%a[i]==0){
				cnt++;
				while(x%a[i]==0) x=x/a[i];
			}
			if (cnt>2) return false;
			if (a[i]>x) break;			
		}
		if (cnt==2) return true;
		return false;
		
	}
	
	public static boolean isp(int x){
		boolean flag = true;
		for(int i = 2; i<x/2+1; i++){
			if (x%i==0) return false;
		}
		return true;
		
	}
	
	public static void main(String args[]){
		Scanner input = new Scanner(System.in);
		
		int n = input.nextInt();
		
		
		
		for(int i = 2; i<=n;i++) if (isp(i)){
			a[la]=i;
			la++;
		}
		
		int cnt = 0;
		for(int i = 6; i<=n;i++){
			if (isap(i)) cnt++;
			
		}
		//for (int i = 0 ; i<=la;i++)	System.out.print(a[i]+" ");
		System.out.println(cnt);
		
		
	}

}
