제출 #778056

#제출 시각아이디문제언어결과실행 시간메모리
778056Jarif_Rahman저울 (IOI15_scales)C++17
19.61 / 100
1 ms300 KiB
#include "scales.h"
#include <bits/stdc++.h>
#define pb push_back
#define f first
#define sc second
using namespace std;
typedef long long int ll;
typedef string str;

void init(int T){

}

void orderCoins(){
    int w[6] = {1, 2, 3, 4, 5, 6};
    /* determine heaviest */{
        int a = getHeaviest(1, 2, 3), b = getHeaviest(4, 5, 6);
        int c = 1;
        if(c == a) c = 2;
        int d = getHeaviest(a, b, c);
        if(d != 6) swap(w[d-1], w[5]);
    }

    sort(w, w+5, [&](int a, int b){
        return getLightest(a, b, w[5]) == a;
    });

    answer(w);
}

컴파일 시 표준 에러 (stderr) 메시지

scales.cpp: In function 'void init(int)':
scales.cpp:10:15: warning: unused parameter 'T' [-Wunused-parameter]
   10 | void init(int T){
      |           ~~~~^
#Verdict Execution timeMemoryGrader output
Fetching results...