# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
398285 | MeGustaElArroz23 | Scales (IOI15_scales) | C++14 | 1 ms | 332 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 "scales.h"
#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef vector<ll> vi;
void init(int T) {
return;
}
int c;
//getHeaviest(A, B, C), getLightest(A, B, C), getMedian(A, B, C)
int menor(int a, int b){
if (a==c) return true;
if (b==c) return false;
return (getMedian(a,b,c)==a);
}
void orderCoins() {
int W[]={1,2,3,4,5,6};
int a=getLightest(1,2,3);
int b=getLightest(4,5,6);
c=a+1;
if (c==b) c++;
c=getLightest(a,b,c);
sort(W,W+6,menor);
answer(W);
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |