# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
286374 | Alexa2001 | Sandwich (JOI16_sandwich) | C++17 | 7183 ms | 12500 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 inf = 1e9;
const int Nmax = 404;
int cells, n, m;
bool bad;
char a[Nmax][Nmax];
int ans[Nmax][Nmax];
int Upper[Nmax][Nmax], Lower[Nmax][Nmax];
void add_upper(int x, int y);
void add_lower(int x, int y)
{
if(Lower[x][y] == 1) bad = 1;
if(Lower[x][y]) return;
Lower[x][y] = 1;
++cells;
if(a[x][y] == 'N') /// adaug dreapta
{
if(a[x][y+1] == 'N')
add_lower(x, y+1);
else if(a[x][y+1] == 'Z')
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |