# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1161662 | MisterReaper | "The Lyuboyn" code (IZhO19_lyuboyn) | C++20 | 20 ms | 6468 KiB |
// Similar to Benq's solution, based on xor basis: https://oj.uz/submission/143064
// Also there is constructive solution like DeBrujin Sequences, see errorgorn's solution: https://oj.uz/submission/288552
#include <bits/stdc++.h>
using i64 = long long;
#ifdef DEBUG
#include "/home/ahmetalp/Desktop/Workplace/debug.h"
#else
#define debug(...) void(23)
#endif
int main() {
std::ios::sync_with_stdio(false);
std::cin.tie(nullptr);
int N, K, T;
std::cin >> N >> K >> T;
std::string S;
std::cin >> S;
if (K % 2 == 0) {
std::cout << "-1\n";
return 0;
}
std::vector<std::pair<int, int>> basis;
for (int i = 0; i < (1 << N); ++i) {
if (__builtin_popcount(i) != K) {
continue;
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |