This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include "registers.h"
#include <bits/stdc++.h>
using namespace std;
void construct_instructions(int s, int n, int k, int q) {
for(int i=k-1;i>=0;i--) {
append_or(0,0,1);
vector<bool> emp(2000,1);
append_store(2,emp);
append_move(5,0);
append_right(5,5,i);
for(int j=0;j<n;j++) {
append_and(2,2,5);
append_right(5,5,k);
}
append_store(3,emp);
for(int j=1;j<2000;j++) {
emp[i]=0;
}
append_store(6,emp);
append_and(2,2,6);
append_add(3,2,3);
append_and(3,0,3);
for(int j=0;j<2000;j++) {
if (j%k!=i||j/k>=n) {
emp[j]=0;
}
else {
emp[j]=1;
}
}
append_store(4,emp);
append_and(3,3,4);
append_or(1,1,3);
append_right(1,1,1);
}
for(int i=1;i<n;i++) {
append_move(i,i-1);
append_right(i,i,k);
}
append_print(0);
append_print(1);
for(int i=1;i<n;i++) {
append_and(0,0,i);
}
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |