| 比赛 | EYOI常规赛 1st | 评测结果 | AAAAAAAAAA |
|---|---|---|---|
| 题目名称 | 奶牛晒衣服 | 最终得分 | 100 |
| 用户昵称 | 张恒畅 | 运行时间 | 0.458 s |
| 代码语言 | C++ | 内存使用 | 3.58 MiB |
| 提交时间 | 2021-12-02 20:11:24 | ||
#include<bits/stdc++.h>
using namespace std;
priority_queue<int>q;
int n, a, b, x;
int t;
int main()
{
freopen("dry.in","r",stdin);
freopen("dry.out","w",stdout);
cin >> n >> a >> b;
for(int i = 1; i <= n; i++)
{
scanf("%d", &x);
q.push(x);
}
while(q.top()- t*a>0)
{
t++;
int k=q.top();
q.pop();
q.push(k-b);
}
cout << t;
}