C.礼物购买
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.
题目描述
有 种物品,第 种物品的价格为 ,每天最多购买 个。
有 天,第 天小K有 的钱,他会不停购买能买得起的最贵的物品。你需要求出他每天会购买多少个物品。
输入格式
第一行两个整数 。
接下来 行每行两个整数 。
接下来 行每行一个整数 。
输出格式
输出 行每行一个整数,第行表示第 天购买的物品数量。
样例
3 3
1 1
2 2
3 3
5
10
15
2
4
6
数据范围与提示
对于 的数据,。
另有 的数据, = 1。
对于 的数据,,,,,。
2023cspj复赛模拟题1(T1-T2)
- Status
- Done
- Rule
- OI
- Problem
- 3
- Start at
- 2023-10-13 15:15
- End at
- 2023-10-17 19:15
- Duration
- 2.5 hour(s)
- Host
- Partic.
- 2