| # | Time | Username | Problem | Language | Result | Execution time | Memory |
|---|---|---|---|---|---|---|---|
| 1332021 | kawhiet | Ljeto (COCI21_ljeto) | C++20 | 1 ms | 344 KiB |
#include <bits/stdc++.h>
using namespace std;
int main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
int n;
cin >> n;
vector<array<int, 3>> x(n);
for (int i = 0; i < n; i++) {
for (int j = 0; j < 3; j++) {
cin >> x[i][j];
}
}
ranges::sort(x);
vector<int> when(9, -20);
int ans1 = 0, ans2 = 0;
for (int i = 0; i < n; i++) {
auto [t, a, b] = x[i];
int res = 100;
if (when[a] >= t - 10) {
res += 50;
}
if (a <= 4) {
ans1 += res;
} else {
ans2 += res;
}
when[a] = t;
}
cout << ans1 << ' ' << ans2 << '\n';
return 0;
}| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
