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 os

import sys

debug = True

if debug and os.path.exists("input.in"):
    input = open("input.in", "r").readline
else:
    debug = False
    input = sys.stdin.readline


def inp():
    return (int(input()))


def inlt():
    return (list(map(int, input().split())))


def insr():
    s = input()
    return s[:len(s) - 1]  # Remove line char from end


def invr():
    return (map(int, input().split()))


def get_primes(max_prime):
    primes = [True] * (max_prime + 1)
    primes[1] = False
    for i in range(2, max_prime + 1):
        x = i + i
        while x <= max_prime:
            primes[x] = False
            x += i
    p = set()
    for i in range(2, max_prime + 1):
        if primes[i]:
            p.add(i)
    return p


test_count = 1
if debug:
    test_count = inp()

for t in range(test_count):
    if debug:
        print("Test Case #", t + 1)
    # Start code here
    n = inp()
    primes = get_primes(n)
    ans = 0
    for x in range(2, n + 1):
        cnt = 0
        for i in range(1, int(x / 2) + 1):
            if i in primes and x % i == 0:
                cnt += 1
            if cnt > 2:
                break
        if cnt == 2:
            ans += 1
            # print(x)
    print(ans)
