Submission #132601

#TimeUsernameProblemLanguageResultExecution timeMemory
132601MoNsTeR_CuBeAncient Books (IOI17_books)C++17
0 / 100
2 ms376 KiB
#include <bits/stdc++.h> #include "books.h" using namespace std; long long minimum_walk(std::vector<int> p, int s) { vector< int > v; for(int i = 0; i < 4; i++){ v.push_back(i); } map< vector< int >, int> mape; int curr = 0; //int curr[24] = {0,6,4,6,6,6,2,6,4,6,6}; int ans[24] = {0,6,4,6,6,6,2,6,4,6,6,6,6,4,6,4,6,6,6,6,6,6,6,6}; do{ for(int a : v) cout << a << ' '; cout << endl; mape[v] = ans[curr++]; }while(next_permutation(v.begin(), v.end())); return mape[p]; }
#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...