結果
| 問題 |
No.678 2Dシューティングゲームの必殺ビーム
|
| コンテスト | |
| ユーザー |
dnish
|
| 提出日時 | 2018-06-18 23:20:36 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 889 bytes |
| コンパイル時間 | 1,469 ms |
| コンパイル使用メモリ | 166,360 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-06-30 17:06:03 |
| 合計ジャッジ時間 | 2,045 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 18 |
ソースコード
#include "bits/stdc++.h"
#define REP(i,n,N) for(int i=(n); i<(N); i++)
#define RREP(i,n,N) for(int i=(N-1); i>=n; i--)
#define CK(n,a,b) ((a)<=(n)&&(n)<(b))
#define ALL(v) (v).begin(),(v).end()
#define p(s) cout<<(s)<<endl
#define p2(a,b) cout<<(a)<<" "<<(b)<<endl
typedef long long ll;
using namespace std;
const int inf=1e9;
int N, xLB, xRB;
int XL[200], YU[200], XR[200], YD[200];
int front[1300],no[1300];
int ans[200];
int main(){
cin>>N>>xLB>>xRB;
REP(i,0,1300){
front[i]=-inf;
no[i]=-1;
}
REP(i,0,N){
cin>>XL[i]>>YU[i]>>XR[i]>>YD[i];
REP(j,max(xLB,XL[i]),min(xRB,XR[i])+1){
if(front[j]<YD[i]){
front[j]=YD[i];
no[j]=i;
}
}
}
REP(i,xLB,xRB+1){
if(no[i]==-1) continue;
ans[no[i]]=1;
}
REP(i,0,N){
p(ans[i]);
}
return 0;
}
dnish