# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
132419 | reda | Scales (IOI15_scales) | C++14 | 17 ms | 380 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>
#include "scales.h"
using namespace std;
void init(int T) {
return;
}
bool cmp(int x,int y)
{
for(int i=1;i<=3;i++)
{
if(x==i||y==i)continue;
int ans=getLightest(x,y,i);
if(ans==i) {ans=getHeaviest(x,y,i);return (ans==y);}
else return (ans==x);
}
}
void orderCoins()
{
int w[6]={1,2,3,4,5,6};
sort(w,w+6,cmp);
answer(w);
return;
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |