#include <bits/stdc++.h>
using namespace std;
int main(){
int n;
cin >> n;
int ls[10], a = 0, b = 0;
for (int i=1;i<=8;i++)ls[i]=-100;
for (int i = 0; i < n; i++) {
int t, x, y;
cin >> t >> x >> y;
if (x <= 4)a += 100+50*(i-ls[x]<10), ls[x] = i;
else b += 100+50*(i-ls[x]<10), ls[x] = i;
}
cout << a << " " << b;
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
1 ms |
348 KB |
Output is correct |
2 |
Incorrect |
0 ms |
360 KB |
Output isn't correct |
3 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
348 KB |
Output is correct |
2 |
Correct |
0 ms |
348 KB |
Output is correct |
3 |
Incorrect |
0 ms |
348 KB |
Output isn't correct |
4 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
1 ms |
348 KB |
Output is correct |
2 |
Incorrect |
0 ms |
360 KB |
Output isn't correct |
3 |
Halted |
0 ms |
0 KB |
- |