| # | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
|---|---|---|---|---|---|---|---|
| 1282713 | gabrielz | 축제 (IOI25_festival) | C++20 | 0 ms | 0 KiB |
#include "festival.h"
std::vector<int> max_coupons(int A, std::vector<int> P, std::vector<int> T) {
std::vector<int> R;
std::sort(P.begin(), P.end());
for (auto price : P) {
if (A >= price) {
A -= price;
R.push_back(price);
} else {
break;
}
}
return R;
}
