# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1162326 | brover29 | The Kingdom of JOIOI (JOI17_joioi) | C++17 | 1 ms | 324 KiB |
#include <bits/stdc++.h>
//qwerty47924692
using namespace std;
using ll = long long;
const ll N=2005;
const string br="617283";
#define sz(a)(ll)a.size()
#define f first
#define s second
ll n,m,a[N][N],b[N][N],mn=1e18,mx=-1e18,c[N][N];
bool is_good(){
bool ok=1;
for(ll i=1;i<=n;i++){
ll cnt=0;
for(ll j=1;j<=m;j++){
ok&=(c[i][j]&b[i][j])==(c[i][j]);
cnt+=(c[i][j]!=c[i][j-1]);
}
ok&=(cnt<=2);
}return ok;
}void clr(){
for(ll i=1;i<=n;i++){
for(ll j=1;j<=m;j++){
c[i][j]=2;
}
}
}
bool check(ll x){
for(ll i=1;i<=n;i++){
for(ll j=1;j<=m;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... |