Submission #471599

#TimeUsernameProblemLanguageResultExecution timeMemory
471599flappybirdNavigation 2 (JOI21_navigation2)C++17
0 / 100
1 ms192 KiB
#include "Anna.h" #include <bits/stdc++.h> typedef int ll; using namespace std; namespace { } // namespace void Anna(int N, int K, std::vector<int> R, std::vector<int> C) { ll i, j, k; for (i = 0; i < N; i++) { for (j = 0; j < N; j++) { ll val = 0; for (k = 0; k < K; k++) { if (R[k] <= i && C[k] <= j) val |= (1 << k); } SetFlag(i, j, val + 1); } } }
#include "Bruno.h" #include <bits/stdc++.h> using namespace std; typedef int ll; namespace { int variable_example = 1; } // namespace std::vector<int> Bruno(int K, std::vector<int> value) { ll k; vector<ll> ret(K); for (k = 0; k < 9; k++) value[k]--; for (k = 0; k < K; k++) { vector<vector<ll>> arr(3, vector<ll>(3)); ll i, j; for (i = 0; i < 9; i++) arr[i / 3][i % 3] = (value[i] & (1 << k)); if (arr[0][0]) ret[k] = 3; else if (arr[0][1]) ret[k] = 3; else if (arr[1][0]) ret[k] = 1; else if (arr[1][1]) ret[k] = 4; else if (arr[1][2]) ret[k] = 0; else ret[k] = 2; } return ret; }

Compilation message (stderr)

Bruno.cpp: In function 'std::vector<int> Bruno(int, std::vector<int>)':
Bruno.cpp:18:9: warning: unused variable 'j' [-Wunused-variable]
   18 |   ll i, j;
      |         ^
Bruno.cpp: At global scope:
Bruno.cpp:8:5: warning: '{anonymous}::variable_example' defined but not used [-Wunused-variable]
    8 | int variable_example = 1;
      |     ^~~~~~~~~~~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...