# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1049606 | vjudge1 | T-Covering (eJOI19_covering) | C++17 | 70 ms | 16588 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include<bits/stdc++.h>
using namespace std;
const int N = 1e6 + 2;
vector<vector<int>> a;
vector<int> xet;
vector<vector<bool>> check, dem, red;
int n, m, q, x[N], y[N];
int ans = 0, tmp = 0, tmp1 = 0;
int xx[] = {-1, -2, -1, 0, 1, 2, 1, 0, -1, 0, 1, 0}, yy[] = {-1, 0, 1, 2, 1, 0, -1, -2, 0, 1, 0, -1};
bool in(int u, int v)
{
if(u < 0 || v < 0 || u >= n || v >= m)
return false;
return true;
}
void dfs(int u, int v)
{
tmp += a[u][v];
tmp1++;
check[u][v] = true;
for(int i = 8; i < 12; i++)
{
if(in(u + xx[i], v + yy[i]) && !dem[u + xx[i]][v + yy[i]] && !red[u + xx[i]][v + yy[i]])
{
dem[u + xx[i]][v + yy[i]] = true;
Compilation message (stderr)
# | 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... |