# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1175360 | ThylOne | Soccer Stadium (IOI23_soccer) | C++20 | 190 ms | 31772 KiB |
#include "soccer.h"
#include<bits/stdc++.h>
using namespace std;
bool a_dans_b(pair<int,int> a, pair<int,int> b){
return b.first<=a.first && a.second<=b.second;
}
int biggest_stadium(int N, std::vector<std::vector<int>> F)
{
int empty = 0;
int cnt= 0;
vector<pair<int,int>> inters;
for(int y = 0 ; y < N ; y++){
int flag = 0;
pair<int,int> inter = {-1,-1};
for(int x = 0 ; x < N ; x++){
if(F[y][x]==0)empty++;
if(flag==0 && F[y][x])continue;
if(flag<=1 && F[y][x]==0){
if(flag==0)inter.first=x;
inter.second=x;
flag=1;
cnt++;
}
if(flag==1 && F[y][x]){
flag=2;
}
}
inters.push_back(inter);
}
if(cnt!=empty){
# | 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... |