# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
499416 |
2021-12-28T11:30:08 Z |
Alisaf9 |
Ljeto (COCI21_ljeto) |
C++14 |
|
1 ms |
204 KB |
#include <bits/stdc++.h>
using namespace std;
int main()
{
int n,q,f=0,s=0;
cin>>n;
pair<int,int>pp[1009];
for(int i=0;i<n;i++)
{
cin>>pp[i].second>>pp[i].first>>q;
}
for(int i=0;i<n;i++)
{
if(pp[i].first<5)
{f+=100;}
else
{s+=100;}
for(int l=0;l<i;l++)
{
if(pp[i].first==pp[l].first)
{
if(pp[i].second-pp[l].second<=10)
{
if(pp[i].first<5)
{f+=50;
break;
}
else
{
s+=50;
break;
}
}
}
}
}
cout<<f<<" "<<s;
return 0;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
204 KB |
Output is correct |
2 |
Correct |
0 ms |
204 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
204 KB |
Output is correct |
2 |
Correct |
0 ms |
204 KB |
Output is correct |
3 |
Correct |
0 ms |
204 KB |
Output is correct |
4 |
Correct |
0 ms |
204 KB |
Output is correct |
5 |
Correct |
0 ms |
204 KB |
Output is correct |
6 |
Correct |
0 ms |
204 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
204 KB |
Output is correct |
2 |
Correct |
0 ms |
204 KB |
Output is correct |
3 |
Correct |
0 ms |
204 KB |
Output is correct |
4 |
Correct |
0 ms |
204 KB |
Output is correct |
5 |
Correct |
0 ms |
204 KB |
Output is correct |
6 |
Correct |
0 ms |
204 KB |
Output is correct |
7 |
Correct |
0 ms |
204 KB |
Output is correct |
8 |
Correct |
0 ms |
204 KB |
Output is correct |
9 |
Correct |
0 ms |
204 KB |
Output is correct |
10 |
Correct |
0 ms |
204 KB |
Output is correct |
11 |
Correct |
1 ms |
204 KB |
Output is correct |
12 |
Correct |
0 ms |
204 KB |
Output is correct |
13 |
Correct |
0 ms |
204 KB |
Output is correct |