Submission #1056683

#TimeUsernameProblemLanguageResultExecution timeMemory
1056683user736482Bit Shift Registers (IOI21_registers)C++17
Compilation error
0 ms0 KiB
#include<bits/stdc++.h> using namespace std; vector<int>zera,jeden4; void minimum(a,b,t){ append_store(t,zera); append_move(98,a); append_not(98); append_add(98,b,98); append_left(98,10,98); append_and(t,b,98); append_not(98); append_and(t,a,98); /*zera[0]=1; append_store(98,zera); zera[0]=0; append_add(98,b,98); append_not(98); append_add(98,a,98); append_left(98,10,98); append_and(t,b,98);*/ } void construct_instructions(int s, int n, int k, int q){ for(int i=0;i<2000;i++){ zera.push_back(0); jeden4.push_back(0); if(i<4); jeden4[i]++; } append_move(1,0); append_left(1,k); append_store(2,jeden4); append_and(1,2,1); minimum(0,1,3); append_move(0,3); }

Compilation message (stderr)

registers.cpp:6:6: error: variable or field 'minimum' declared void
    6 | void minimum(a,b,t){
      |      ^~~~~~~
registers.cpp:6:14: error: 'a' was not declared in this scope
    6 | void minimum(a,b,t){
      |              ^
registers.cpp:6:16: error: 'b' was not declared in this scope
    6 | void minimum(a,b,t){
      |                ^
registers.cpp:6:18: error: 't' was not declared in this scope; did you mean 'tm'?
    6 | void minimum(a,b,t){
      |                  ^
      |                  tm
registers.cpp: In function 'void construct_instructions(int, int, int, int)':
registers.cpp:31:9: warning: this 'if' clause does not guard... [-Wmisleading-indentation]
   31 |         if(i<4);
      |         ^~
registers.cpp:32:13: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if'
   32 |             jeden4[i]++;
      |             ^~~~~~
registers.cpp:34:5: error: 'append_move' was not declared in this scope
   34 |     append_move(1,0);
      |     ^~~~~~~~~~~
registers.cpp:35:5: error: 'append_left' was not declared in this scope
   35 |     append_left(1,k);
      |     ^~~~~~~~~~~
registers.cpp:36:5: error: 'append_store' was not declared in this scope
   36 |     append_store(2,jeden4);
      |     ^~~~~~~~~~~~
registers.cpp:37:5: error: 'append_and' was not declared in this scope
   37 |     append_and(1,2,1);
      |     ^~~~~~~~~~
registers.cpp:38:5: error: 'minimum' was not declared in this scope
   38 |     minimum(0,1,3);
      |     ^~~~~~~