# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
655706 |
2022-11-05T10:49:07 Z |
MrAndria |
Ljeto (COCI21_ljeto) |
C++14 |
|
1 ms |
340 KB |
#include <bits/stdc++.h>
using namespace std;
#define pb push_back
#define f first
#define s second
map <int,int> mp;
int a[10000],b[10000],t[10000];
int sum2,n,sum1;
int main(){
ios::sync_with_stdio(false);
cin.tie(NULL);
cin>>n;
for(int i=0;i<n;i++){
cin>>t[i]>>a[i]>>b[i];
if((t[i]-mp[a[i]])<=10 and mp[a[i]]!=0){
if(a[i]>=5){
sum2+=150;
}else{
sum1+=150;
}
mp[a[i]]=t[i];
}else{
if(a[i]>=5){
sum2+=100;
}else{
sum1+=100;
}
mp[a[i]]=t[i];
}
}
cout<<sum1<<" "<<sum2;
}
/*
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
annnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnna
an%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%na
an %na
an %na
an %na
an %na
an %na
an %na
an %na
annnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnna
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
*/
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
328 KB |
Output is correct |
2 |
Correct |
1 ms |
340 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
212 KB |
Output is correct |
5 |
Correct |
1 ms |
340 KB |
Output is correct |
6 |
Correct |
1 ms |
212 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
328 KB |
Output is correct |
4 |
Correct |
1 ms |
340 KB |
Output is correct |
5 |
Correct |
1 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
212 KB |
Output is correct |
7 |
Correct |
1 ms |
340 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
1 ms |
212 KB |
Output is correct |
10 |
Correct |
1 ms |
324 KB |
Output is correct |
11 |
Correct |
1 ms |
340 KB |
Output is correct |
12 |
Correct |
1 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
328 KB |
Output is correct |