# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
418527 | 2021-06-05T12:53:57 Z | Tangent | Vision Program (IOI19_vision) | C++17 | 15 ms | 1668 KB |
#include "vision.h" #include "bits/stdc++.h" using namespace std; typedef long long ll; typedef pair<int, int> pii; typedef pair<ll, ll> pll; typedef vector<int> vii; typedef vector<ll> vll; typedef vector<pii> vpii; typedef vector<pll> vpll; typedef vector<vii> vvii; typedef vector<vll> vvll; typedef vector<vpii> vvpii; typedef vector<vpll> vvpll; #define ffor(i, a, b) for (ll i = a; i < b; i++) #define rep(i, n) ffor(i, 0, n) #define forin(x, a) for (auto &x: a) #define all(a) a.begin(), a.end() void construct_network(int H, int W, int K) { map<int, vii> diaga, diagb; rep(i, H) { rep(j, W) { int k = W * i + j; diaga[i + j].emplace_back(k); diagb[i - j].emplace_back(k); } } vii inda, indb, res; forin(diag, diaga) { inda.emplace_back(add_or(diag.second)); } forin(diag, diagb) { indb.emplace_back(add_or(diag.second)); } rep(i, inda.size() - K) { res.emplace_back(add_and({inda[i], inda[i + K]})); } rep(i, indb.size() - K) { res.emplace_back(add_and({indb[i], indb[i + K]})); } add_or(res); }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 204 KB | Output is correct |
2 | Correct | 1 ms | 204 KB | Output is correct |
3 | Correct | 1 ms | 288 KB | Output is correct |
4 | Correct | 1 ms | 284 KB | Output is correct |
5 | Correct | 1 ms | 204 KB | Output is correct |
6 | Correct | 1 ms | 204 KB | Output is correct |
7 | Incorrect | 1 ms | 292 KB | on inputs (0, 2), (1, 0), expected 0, but computed 1 |
8 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 204 KB | Output is correct |
2 | Correct | 1 ms | 204 KB | Output is correct |
3 | Correct | 1 ms | 288 KB | Output is correct |
4 | Correct | 1 ms | 284 KB | Output is correct |
5 | Correct | 1 ms | 204 KB | Output is correct |
6 | Correct | 1 ms | 204 KB | Output is correct |
7 | Incorrect | 1 ms | 292 KB | on inputs (0, 2), (1, 0), expected 0, but computed 1 |
8 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 204 KB | Output is correct |
2 | Correct | 1 ms | 204 KB | Output is correct |
3 | Correct | 1 ms | 288 KB | Output is correct |
4 | Correct | 1 ms | 284 KB | Output is correct |
5 | Correct | 1 ms | 204 KB | Output is correct |
6 | Correct | 1 ms | 204 KB | Output is correct |
7 | Incorrect | 1 ms | 292 KB | on inputs (0, 2), (1, 0), expected 0, but computed 1 |
8 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 204 KB | Output is correct |
2 | Correct | 1 ms | 204 KB | Output is correct |
3 | Correct | 1 ms | 288 KB | Output is correct |
4 | Correct | 1 ms | 284 KB | Output is correct |
5 | Correct | 1 ms | 204 KB | Output is correct |
6 | Correct | 1 ms | 204 KB | Output is correct |
7 | Incorrect | 1 ms | 292 KB | on inputs (0, 2), (1, 0), expected 0, but computed 1 |
8 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 332 KB | Output is correct |
2 | Correct | 1 ms | 332 KB | Output is correct |
3 | Correct | 1 ms | 332 KB | Output is correct |
4 | Correct | 1 ms | 332 KB | Output is correct |
5 | Correct | 1 ms | 284 KB | Output is correct |
6 | Correct | 1 ms | 332 KB | Output is correct |
7 | Correct | 1 ms | 332 KB | Output is correct |
8 | Correct | 1 ms | 332 KB | Output is correct |
9 | Correct | 1 ms | 332 KB | Output is correct |
10 | Correct | 1 ms | 288 KB | Output is correct |
11 | Correct | 1 ms | 332 KB | Output is correct |
12 | Correct | 1 ms | 332 KB | Output is correct |
13 | Correct | 1 ms | 332 KB | Output is correct |
14 | Correct | 1 ms | 292 KB | Output is correct |
15 | Correct | 1 ms | 332 KB | Output is correct |
16 | Correct | 1 ms | 332 KB | Output is correct |
17 | Correct | 1 ms | 332 KB | Output is correct |
18 | Correct | 1 ms | 288 KB | Output is correct |
19 | Correct | 1 ms | 332 KB | Output is correct |
20 | Correct | 1 ms | 332 KB | Output is correct |
21 | Correct | 0 ms | 204 KB | Output is correct |
22 | Correct | 1 ms | 296 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 204 KB | Output is correct |
2 | Correct | 1 ms | 204 KB | Output is correct |
3 | Correct | 2 ms | 420 KB | Output is correct |
4 | Correct | 2 ms | 332 KB | Output is correct |
5 | Correct | 2 ms | 332 KB | Output is correct |
6 | Correct | 2 ms | 332 KB | Output is correct |
7 | Correct | 2 ms | 332 KB | Output is correct |
8 | Correct | 3 ms | 460 KB | Output is correct |
9 | Correct | 3 ms | 460 KB | Output is correct |
10 | Correct | 3 ms | 460 KB | Output is correct |
11 | Correct | 3 ms | 424 KB | Output is correct |
12 | Correct | 3 ms | 516 KB | Output is correct |
13 | Correct | 1 ms | 332 KB | Output is correct |
14 | Correct | 1 ms | 332 KB | Output is correct |
15 | Correct | 1 ms | 332 KB | Output is correct |
16 | Correct | 1 ms | 332 KB | Output is correct |
17 | Correct | 1 ms | 332 KB | Output is correct |
18 | Correct | 1 ms | 288 KB | Output is correct |
19 | Correct | 1 ms | 332 KB | Output is correct |
20 | Correct | 8 ms | 988 KB | Output is correct |
21 | Incorrect | 8 ms | 984 KB | on inputs (0, 0), (199, 99), expected 0, but computed 1 |
22 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 15 ms | 1668 KB | on inputs (126, 120), (176, 169), expected 0, but computed 1 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 204 KB | Output is correct |
2 | Correct | 1 ms | 204 KB | Output is correct |
3 | Correct | 1 ms | 288 KB | Output is correct |
4 | Correct | 1 ms | 284 KB | Output is correct |
5 | Correct | 1 ms | 204 KB | Output is correct |
6 | Correct | 1 ms | 204 KB | Output is correct |
7 | Incorrect | 1 ms | 292 KB | on inputs (0, 2), (1, 0), expected 0, but computed 1 |
8 | Halted | 0 ms | 0 KB | - |