# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
992534 | Khanhcsp2 | Nafta (COI15_nafta) | C++14 | 243 ms | 163664 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>
#define el '\n'
#define fi first
#define sc second
#define int ll
#define pii pair<int, int>
#define all(v) v.begin(), v.end()
using namespace std;
using ll=long long;
using ull=unsigned long long;
using ld=long double;
const int mod=1e9+7;
const int N=2e3+11;
int hx[]={0, 0, -1, 1};
int hy[]={-1, 1, 0, 0};
int m, n;
char a[N][N];
int v[N][N], vit[N][N], l[N], r[N], val[N], mi=N, sum, ma, s[N][N];
vector<int> dp1, dp2;
bool valid(int x, int y)
{
if(x<1 || x>m || y<1 || y>n || vit[x][y]) return 0;
return 1;
}
void dfs(int i, int j)
{
if(vit[i][j]) return;
vit[i][j]=1;
sum+=v[i][j];
mi=min(mi, j);
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |