Submission #118964

#TimeUsernameProblemLanguageResultExecution timeMemory
118964oolimry저울 (IOI15_scales)C++14
0 / 100
3 ms512 KiB
#include "scales.h" #include <bits/stdc++.h> using namespace std; void init(int T) { /* ... */ } void orderCoins() { /* ... */ int W[] = {1, 2, 3, 4, 5, 6}; W[0] = getLightest(1,2,3); W[1] = getLightest(4,5,6); int smth = 1; if(W[0] == 1 || W[1] == 1) smth = 2; if(W[0] == 2 || W[1] == 2) smth = 3; if(getLightest(W[0],W[1],smth) == W[1]) swap(W[0],W[1]); W[4] = getHeaviest(1,2,3); W[5] = getHeaviest(4,5,6); smth = W[0]; if(getHeaviest(W[4],W[5],smth) == W[1]) swap(W[4],W[5]); set<int> s = {W[0],W[1],W[4],W[5]}; int a = -1, b = -1; for(int i = 1;i <= 6;i++){ if(s.find(i) == s.end()){ if(a == -1) a = i; else b = i; } } W[2] = getLightest(a,b,W[5]); if(W[2] == a) W[3] = b; else W[3] = a; answer(W); }

Compilation message (stderr)

In file included from grader.c:2:0:
graderlib.c: In function 'void answer(int*)':
graderlib.c:53:5: warning: this 'if' clause does not guard... [-Wmisleading-indentation]
     if (_ghksjhdfkae19ga_ > 1) 
     ^~
graderlib.c:56:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if'
  for (i = 0; i < 6; i++) {
  ^~~
scales.cpp: In function 'void init(int)':
scales.cpp:4:15: warning: unused parameter 'T' [-Wunused-parameter]
 void init(int T) {
               ^
#Verdict Execution timeMemoryGrader output
Fetching results...