# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
974253 | vjudge1 | Ljeto (COCI21_ljeto) | C++17 | 0 ms | 348 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include<bits/stdc++.h>
using namespace std;
int main(){
int n; cin >> n;
int ev[n][3];
for(int i = 1; i <= n; i++){
cin >> ev[i][0] >> ev[i][1] >> ev[i][2];
}
int skA, skB, idx;
for(int i = 1; i <= n; i++){
if(ev[i][1] >= 1 && ev[i][1] <= 4){
skA += 100;
idx = 0;
} else{
skB += 100;
idx = 1;
}
if(i > 1 && ev[i][0] <= ev[i-1][0]+10 && ev[i][1] == ev[i-1][1]){
if(idx) skB += 50;
else skA += 50;
}
}
cout << skA << " " << skB << endl;
return 0;
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |