Submission #358311

#TimeUsernameProblemLanguageResultExecution timeMemory
358311kylych03Scales (IOI15_scales)C++14
Compilation error
0 ms0 KiB
#include "scales.h" #include <bits/stdc++.h> #include "grader.cpp" using namespace std; void init(int T) { /* ... */ } void orderCoins() { int w[] = {1, 2, 3, 4, 5, 6}; /// int x = getLightest(w[0], w[1], w[2]); if ( x == w[2]) swap(w[0] , w[2]); if ( x == w[1]) swap(w[0] , w[1]); // x = getMedian (w[0], w[1], w[2]); if ( x == w[2]) swap(w[2] , w[1]); // swap(w[0], w[3]); swap(w[1], w[4]); swap(w[2], w[5]); // x = getLightest(w[0], w[1], w[2]); if ( x == w[2]) swap(w[0] , w[2]); if ( x == w[1]) swap(w[0] , w[1]); // x = getMedian (w[0], w[1], w[2]); if ( x == w[2]) swap(w[2] , w[1]); x = getMedian (w[0], w[1], w[4]); if( x == w[0]){ swap(w[0] , w[3]); swap(w[1] , w[4]); swap(w[2] , w[3]); swap(w[3] , w[4]); x = getMedian (w[2], w[3], w[5]); if(x == w[2]){ swap(w[5], w[2]); swap(w[5], w[3]); swap(w[5], w[4]); } else if(x == w[5]){ swap(w[5], w[3]); swap(w[5], w[4]); } else{ x = getMedian (w[3], w[4], w[5]); if( x == w[5]) swap( w[4], w[5]); } } else if(x == w[1]){ swap(w[1], w[3]); swap(w[2], w[3]); x = getMedian (w[0], w[1], w[2]); if(x == w[0]) swap(w[0], w[1]); if(x == w[2]) swap(w[2], w[1]); x = getMedian (w[3], w[4], w[5]); if(x == w[3] || x == w[5]) swap( w[3], w[4]); if( x == w[5]) swap( w[4], w[5]); } else { swap(w[1], w[3]); swap(w[2], w[4]); x = getMedian (w[0], w[1], w[2]); if(x == w[0]) swap(w[0], w[1]); x = getMedian (w[3], w[4], w[5]); if(x == w[3]){ swap(w[3], w[5]); swap(w[4], w[5]); } if( x == w[5]) swap(w[4], w[5]); } answer(w); }

Compilation message (stderr)

scales.cpp:3:10: fatal error: grader.cpp: No such file or directory
    3 | #include "grader.cpp"
      |          ^~~~~~~~~~~~
compilation terminated.