# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
916985 | Jakub_Wozniak | Permutation (APIO22_perm) | C++17 | 1 ms | 348 KiB |
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 <bits/stdc++.h>
using namespace std;
vector <pair<int,int>> V;
vector<int> construct_permutation(long long n)
{
if(n == 2)return {0};
if(n == 3)return {1,0};
if(n == 4)return {0,1};
long long MAX = 300;
vector <int> v;
vector <int> B;
long long akt = 0;
int r[200];
while(n)
{
B.push_back(n%2);
n/=2;
}
reverse(B.begin() , B.end());
if(B[1] == 1)
{
v.push_back(2);
v.push_back(1);
akt = 2;
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |