제출 #241846

#제출 시각아이디문제언어결과실행 시간메모리
241846tleontest1Unscrambling a Messy Bug (IOI16_messy)C++14
38 / 100
6 ms384 KiB
#include "messy.h" #pragma GCC optimize ("O3") #pragma GCC target ("sse4") #pragma GCC optimize ("unroll-loops") #pragma GCC target ("avx2") #include <bits/stdc++.h> using namespace std; typedef long long lo; typedef pair< lo,lo > PII; #define fi first #define se second #define mp make_pair #define endl "\n" #define pb push_back #define fio() ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL) #define FOR for(int i=1;i<=n;i++) #define mid ((start+end)/2) #define ort ((bas+son)/2) const lo inf = 1000000000000000000; const lo KOK = 100000; const lo LOG = 30; const lo li = 500005; const lo mod = 1000000007; int cev; string s,ss; vector<int> v; std::vector<int> restore_permutation(int n, int w, int r) { FOR{ s+='0'; ss+='0'; } FOR{ s[i-1]='1'; //~ cout<<s<<endl; add_element(s); } compile_set(); FOR v.pb(0); FOR{ for(int j=0;j<n;j++){ if(ss[j]=='1')continue; string st=ss; st[j]='1'; //~ cout<<st<<endl; if(check_element(st)==0)continue; ss[j]='1'; //~ cout<<i<<endl; v[j]=i-1; break; } } return v; }
#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...