Submission #560254

#TimeUsernameProblemLanguageResultExecution timeMemory
560254dooweyBit Shift Registers (IOI21_registers)C++17
22 / 100
3 ms900 KiB
#include "registers.h" #include <bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<int, int> pii; #define fi first #define se second #define mp make_pair int b = 2000; void construct_instructions(int s, int n, int k, int q) { vector<bool> ss(b); vector<bool> zz(b); for(int i = 0 ; i < b; i ++ ){ if(i < k) ss[i] = 1; else ss[i] = 0; } vector<bool> qq(b); qq[k] = 1; append_store(1, ss); append_store(6, qq); for(int i = 1 ; i < n; i ++ ){ // store minimum at 0 // compare with i append_right(2, 0, i * k); append_move(3, 0); append_not(3, 3); append_and(2, 2, 1); append_and(3, 3, 1); append_add(4, 2, 3); append_and(4, 6, 4); append_store(5, zz); for(int j = k ; j > 0 ; j -- ){ append_right(7, 4, j); append_or(5, 5, 7); } append_not(3, 3); append_and(3, 1, 3); append_and(3, 3, 5); append_not(5, 5); append_and(2, 2, 5); append_or(2, 2, 3); append_not(8, 1); append_and(0, 0, 8); append_or(0, 0, 2); append_or(0, 0, 3); } }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...