# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
667600 | eric | Table Tennis (info1cup20_tabletennis) | C++14 | 34 ms | 2260 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, k, wrong;
long long int som = 0;
scanf("%d %d", &n, &k);
int v[n + k];
for(int i = 0; i < n + k; i++){
scanf("%d", &v[i]);
som += v[i];
}
for(int i = 0; i < n + k; i++){
float m = ((som - v[i])*2)/n;
//printf("%d\n", m);
float comp = v[(i + 1)%(n + k)] + v[(i + 2)%(n + k)];
if(m == comp){
wrong = v[i];
break;
}
}
sort(v, v + (n + k));
for(int i = 0; i < n + k; i++){
if(v[i] == wrong)continue;
printf("%d ", v[i]);
}
}
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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |