Submission #1231247

#TimeUsernameProblemLanguageResultExecution timeMemory
1231247damamilaNavigation 2 (JOI21_navigation2)C++20
7 / 100
331 ms880 KiB
#include "Anna.h" #include <bits/stdc++.h> using namespace std; namespace {} // namespace void Anna(int N, int K, std::vector<int> R, std::vector<int> C) { for (int r = 0; r < N; r++) { for (int c = 0; c < N; c++) { int tmp = 0; for (int i = 0; i < K; i++) { int base = 1; for (int j = 0; j < i; j++) base = base*5; if (r < R[i]) tmp += 2*base; else if (r > R[i]) tmp += 3*base; else if (c < C[i]) tmp += 0*base; else if (c > C[i]) tmp += 1*base; else tmp += 4*base; //~ cerr << field[r][c]/base << " "; } SetFlag(r, c, tmp+1); //~ cerr << endl; } //~ cerr << endl; } }
#include "Bruno.h" #include <bits/stdc++.h> using namespace std; namespace { //~ int variable_example = 1; } // namespace std::vector<int> Bruno(int K, std::vector<int> value) { vector<int> res(K, 0); if (value.size() < 5) return res; int flag = value[4]-1; for (int i = 0; i < K; i++) { res[i] = flag%5; flag /= 5; //~ cerr << flag << " " << res[i] << endl; } return res; }
#Verdict Execution timeMemoryGrader output
Fetching results...