# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
167416 | GioChkhaidze | Bomb (IZhO17_bomb) | C++14 | 570 ms | 121668 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
#define Tree int h,int l,int r
#define Left 2*h,l,(l+r)/2
#define Right 2*h+1,(l+r)/2+1,r
#define F first
#define S second
using namespace std;
const int N=2505;
int n,m,width=1e9,length=1e9,last,D[N][N],Dr[N][N],X,Y;
string s[N],S;
vector < pair < int , pair < int , int > > > v;
inline bool check(int x,int y) {
for (int i=0; i<=n; i++)
for (int j=0; j<=m; j++)
Dr[i][j]=0;
for (int i=0; i<n; i++)
for (int j=0; j<m; j++)
if (D[i+x][j+y]-D[i][j+y]-D[i+x][j]+D[i][j]==0 && s[i][j]=='1')
Dr[i+1][j+1]=Dr[i][j+1]+Dr[i+1][j]-Dr[i][j]+1;
else
Dr[i+1][j+1]=Dr[i][j+1]+Dr[i+1][j]-Dr[i][j];
for (int i=1; i<=n; i++)
for (int j=1; j<=m; j++)
if (s[i-1][j-1]=='1') {
X=max(i-x,0),Y=max(j-y,0);
if (Dr[i][j]-Dr[i][Y]-Dr[X][j]+Dr[X][Y]==0) return 0;
}
컴파일 시 표준 에러 (stderr) 메시지
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |