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.FileReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java .util.*;
public class Contest {
	public static void main(String [] yahia_mostafa) throws IOException,InterruptedException{
		Scanner sc =new Scanner(System.in);
		PrintWriter pw =new PrintWriter(System.out);
		boolean[] isPrime =new boolean[30001];
		Arrays.fill(isPrime, true);
		for (int i=2;i<=Math.sqrt(3000);++i) {
			if (isPrime[i]) {
				for (int j=i*i;j<=3000;j+=i)
					isPrime[j]=false;
			}
		}
		Queue<Integer> q =new LinkedList<Integer>();
		for (int i = 2;i<=3000;++i)
			if (isPrime[i])
				q.add(i);
		int [] prime =new int [q.size()];
		for (int i =0;!q.isEmpty();++i)
			prime[i]=q.poll();
		int n =sc.nextInt();
		int counter=0;
		for (int i=6;i<=n;++i) {
			HashSet<Integer> hSet=new HashSet<Integer>();
			int j=0;
			if (!isPrime[i]) {
				int z=i;
				while (z>1&&j<3000) {
					if (z%prime[j]==0) {
						z/=prime[j];
						hSet.add(prime[j]);
					}else {
						++j;
					}
				}
				if(z==1&&hSet.size()==2)
					++counter;
			}
		}
		pw.println(counter);
		pw.close();
	}
	static long gcd(long a, long b) 
	{ 
	    if (a == 0) 
	        return b; 
	    return gcd(b % a, a); 
	}
	public static int fac(int x) {
		if (x==1||x==0)
			return 1;
		return x*fac(x-1);
	}
	static class Scanner {
		StringTokenizer stringTokenizer;
		BufferedReader bfBufferedReader;
		public Scanner(InputStream system) {
			bfBufferedReader=new BufferedReader(new InputStreamReader( system));
		}
		 public Scanner(String file) throws Exception {
	            bfBufferedReader = new BufferedReader(new FileReader( file));
	        }			 
	        public String next() throws IOException {
	            while (stringTokenizer == null || !stringTokenizer.hasMoreTokens())
	                stringTokenizer = new StringTokenizer( bfBufferedReader.readLine());
	            return stringTokenizer.nextToken();
	        }
	 
	        public String nextLine() throws IOException {
	            return bfBufferedReader.readLine();
	        }
	 
	        public int nextInt() throws IOException {
	            return Integer.parseInt(next());
	        }
	 
	        public double nextDouble() throws IOException {
	            return Double.parseDouble(next());
	        }
	 
	        public char nextChar() throws IOException {
	            return next().charAt(0);
	        }
	 
	        public Long nextLong() throws IOException {
	            return Long.parseLong(next());
	        }
	 
	        public boolean ready() throws IOException {
	            return bfBufferedReader.ready();
	        }
	 
	        public void waitForInput() throws InterruptedException {
	            Thread.sleep(3000);
	        }
	    }
	}