# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
897093 | 2024-01-02T14:25:29 Z | irmuun | 축구 경기장 (IOI23_soccer) | C++17 | 275 ms | 35852 KB |
#include<bits/stdc++.h> #include "soccer.h" using namespace std; #define ll long long #define pb push_back #define ff first #define ss second #define all(s) s.begin(),s.end() #define rall(s) s.rbegin(),s.rend() int biggest_stadium(int n,vector<vector<int>>F){ vector<pair<int,int>>u; int total=0; bool ok=true; for(int i=0;i<n;i++){ vector<int>v; for(int j=0;j<n;j++){ if(F[i][j]==0){ total++; v.pb(j); } } for(int j=1;j<v.size();j++){ if(v[j-1]+1!=v[j]){ ok=false; } } if(v.size()>0){ u.pb({v[0],v.back()}); } } for(int j=0;j<n;j++){ vector<int>v; for(int i=0;i<n;i++){ if(F[i][j]==0){ v.pb(i); } } for(int i=1;i<v.size();i++){ if(v[i-1]+1!=v[i]){ ok=false; } } } for(auto x:u){ for(auto y:u){ if(x.ss<y.ff||y.ss<x.ff){ ok=false; } } } if(!ok){ if(total==1){ return 2; } return 1; } return total; }
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Partially correct | 1 ms | 348 KB | partial |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 344 KB | ok |
2 | Correct | 0 ms | 348 KB | ok |
3 | Correct | 1 ms | 348 KB | ok |
4 | Correct | 1 ms | 348 KB | ok |
5 | Correct | 1 ms | 348 KB | ok |
6 | Partially correct | 1 ms | 344 KB | partial |
7 | Partially correct | 1 ms | 348 KB | partial |
8 | Partially correct | 21 ms | 2832 KB | partial |
9 | Partially correct | 275 ms | 35852 KB | partial |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 344 KB | ok |
2 | Correct | 0 ms | 348 KB | ok |
3 | Partially correct | 1 ms | 344 KB | partial |
4 | Partially correct | 1 ms | 348 KB | partial |
5 | Partially correct | 1 ms | 344 KB | partial |
6 | Incorrect | 0 ms | 348 KB | wrong |
7 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Partially correct | 1 ms | 348 KB | partial |
2 | Correct | 1 ms | 344 KB | ok |
3 | Correct | 0 ms | 348 KB | ok |
4 | Partially correct | 1 ms | 344 KB | partial |
5 | Partially correct | 1 ms | 348 KB | partial |
6 | Partially correct | 1 ms | 344 KB | partial |
7 | Incorrect | 0 ms | 348 KB | wrong |
8 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Partially correct | 1 ms | 348 KB | partial |
2 | Correct | 1 ms | 344 KB | ok |
3 | Correct | 0 ms | 348 KB | ok |
4 | Correct | 1 ms | 348 KB | ok |
5 | Correct | 1 ms | 348 KB | ok |
6 | Partially correct | 1 ms | 344 KB | partial |
7 | Partially correct | 1 ms | 348 KB | partial |
8 | Partially correct | 1 ms | 344 KB | partial |
9 | Incorrect | 0 ms | 348 KB | wrong |
10 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Partially correct | 1 ms | 348 KB | partial |
2 | Correct | 1 ms | 344 KB | ok |
3 | Correct | 0 ms | 348 KB | ok |
4 | Correct | 1 ms | 348 KB | ok |
5 | Correct | 1 ms | 348 KB | ok |
6 | Partially correct | 1 ms | 344 KB | partial |
7 | Partially correct | 1 ms | 348 KB | partial |
8 | Partially correct | 1 ms | 344 KB | partial |
9 | Incorrect | 0 ms | 348 KB | wrong |
10 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Partially correct | 1 ms | 348 KB | partial |
2 | Correct | 1 ms | 344 KB | ok |
3 | Correct | 0 ms | 348 KB | ok |
4 | Correct | 1 ms | 348 KB | ok |
5 | Correct | 1 ms | 348 KB | ok |
6 | Correct | 1 ms | 348 KB | ok |
7 | Partially correct | 1 ms | 344 KB | partial |
8 | Partially correct | 1 ms | 348 KB | partial |
9 | Partially correct | 21 ms | 2832 KB | partial |
10 | Partially correct | 275 ms | 35852 KB | partial |
11 | Partially correct | 1 ms | 344 KB | partial |
12 | Partially correct | 1 ms | 348 KB | partial |
13 | Partially correct | 1 ms | 344 KB | partial |
14 | Incorrect | 0 ms | 348 KB | wrong |
15 | Halted | 0 ms | 0 KB | - |