제출 #1197339

#제출 시각아이디문제언어결과실행 시간메모리
1197339kadir순열 (APIO22_perm)C++20
10 / 100
1 ms328 KiB
#include<bits/stdc++.h> #include "perm.h" #define ull unsigned long long #define ll long long #define ff first #define ss second #define pb push_back using namespace std; const ll mod=1e9+7; const ll inf=1e18; const ll mxn=1e6+5; const ll MAX=1e9+6; const ll logk=18; vector<int> construct_permutation(ll k) { int n=log2(k); vector<int> v(n); iota(v.begin(),v.end(),0); for(int i=n-1; i>=0; i--) { if(k&(1LL<<i)) { v.pb(0); for(int j=v.size()-1; j>i; j--) { v[j]=v[j-1]; } v[i]=n; n++; } } return v; } //int main() { // ios::sync_with_stdio(false); // cin.tie(0); // cout.tie(0); //}
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...