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.*;
import java.io.*;

public class Main implements Runnable {
	private void solution() throws IOException {
		int res = 0;
		int n = in.nextInt();
		for (int i = 2; i <= n; ++i) {
			if (almostPrime(i)) {
				++res;
			}
		}
		out.println(res);
	}

	private boolean almostPrime(int n) {
		int cnt = 0;
		for (int i = 2; i * i <= n; ++i) {
			if (n % i == 0) {
				++cnt;
				while (n % i == 0) {
					n /= i;
				}
			}
		}
		if (n > 1) {
			++cnt;
		}
		return cnt == 2;
	}

	public void run() {
		try {
			// in = new Scanner(new FileReader(fileName + ".in"));
			// out = new PrintWriter(fileName + ".out");
			solution();
			in.reader.close();
			out.close();
		} catch (Exception e) {
			e.printStackTrace();
			System.exit(1);
		}
	}
	String fileName = "";

	private class Scanner {
		BufferedReader reader;
		StringTokenizer tokenizer;

		public Scanner(Reader reader) {
			this.reader = new BufferedReader(reader);
			this.tokenizer = new StringTokenizer("");
		}

		public double nextDouble() throws IOException {
			return Double.parseDouble(in.next());
		}

		public boolean hasNext() throws IOException {
			while (!tokenizer.hasMoreTokens()) {
				String next = reader.readLine();
				if (next == null) {
					return false;
				}
				tokenizer = new StringTokenizer(next);
			}
			return true;
		}

		public String next() throws IOException {
			hasNext();
			return tokenizer.nextToken();
		}

		public int nextInt() throws IOException {
			return Integer.parseInt(next());
		}

		public String nextLine() throws IOException {
			tokenizer = new StringTokenizer("");
			return reader.readLine();
		}
	}

	public static void main(String[] args) throws IOException {
		new Thread(null, new Main(), "", 1 << 28).start();
	}
	PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
	Scanner in = new Scanner(new InputStreamReader(System.in));
}
