n, k = map(int, input().split()) prime_dict = dict() for i in range(2, n + 1): prime_dict[i] = 0 count = 0 for i in range(2, n + 1): if prime_dict[i] == 0: for j in range(i, n + 1, i): prime_dict[j] += 1 if prime_dict[j] == k: count += 1 # print(prime_dict) print(count)