#C. [GESP202403 五级] 2. B-smooth 数

    Type: Default 1000ms 256MiB

[GESP202403 五级] 2. B-smooth 数

You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.

题目描述

小杨同学想寻找一种名为 B-smooth 数的正整数。

如果一个正整数的最大质因子不超过 B,则该正整数为 B-smooth 数。小杨同学想知道,对于给定的 n 和 B,有多少个不超过 n 的 B-smooth 数。

输入格式

第一行包含两个正整数 n 和 B,含义如题面所示。

输出格式

输出一个非负整数,表示不超过 n 的 B-smooth 数的数量。

样例

10 3
7

提示

image

对全部的测试数据,保证 1n,B1061≤n,B≤10^6

C++ GESP 2024年3月 五级

Not Attended
Status
Done
Rule
OI
Problem
3
Start at
2024-11-9 17:00
End at
2024-11-18 1:00
Duration
200 hour(s)
Host
Partic.
20