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
# from time import time
# from time import sleep

def isPrime(n) :
    if n == 0 or n == 1 : return False
    else :
        k = 2
        while k ** 2 < n :
            if n % k == 0 :
                return False
            k += 1
        if k ** 2 == n : return False
    return True

def factors(n , primes) :
    k = 0
    lst = []
    while n != 1 :
        if n % primes[k] == 0 :
            if primes[k] not in lst :
                lst.append(primes[k])
            n //= primes[k]
        else :
            k += 1
    return True if len(lst) == 2 else False

if __name__ == "__main__" :
    # start = time()
    primes = []
    for i in range(3001) :
        if isPrime(i) :
            primes.append(i)
    n = int(input())
    count = 0
    for i in range(1,n+1) :
        if factors(i , primes) :
            count += 1
    print(count)
    # print(time() - start)
