bzoj3715 [PA2014]Lustra 暴力
来源:互联网 发布:淘宝的国行jbl靠谱吗 编辑:程序博客网 时间:2024/06/03 19:33
签到题,送经验。
#include<cstdio>#include<algorithm>#include<cstring>#define fo(i,a,b) for(int i=a;i<=b;i++)#define fd(i,a,b) for(int i=a;i>=b;i--)using namespace std;typedef long long ll;const int N=2e5+5;int n,m;int w1,w2,h1,h2,a1[N],a2[N],b1[N],b2[N];int main(){ int cas; scanf("%d",&cas); while (cas--) { scanf("%d",&n); w1=h1=1e9; w2=h2=0; fo(i,1,n) { scanf("%d%d%d%d",&a1[i],&a2[i],&b1[i],&b2[i]); w1=min(w1,a1[i]); w2=max(w2,a2[i]); h1=min(h1,b1[i]); h2=max(h2,b2[i]); } bool flag=0; fo(i,1,n) { if (a1[i]==w1&&a2[i]==w2&&b1[i]==h1&&b2[i]==h2)flag=1; if (flag)break; } if (flag)printf("TAK\n"); else printf("NIE\n"); }}
阅读全文
0 0
- bzoj3715 [PA2014]Lustra 暴力
- bzoj3715 [PA2014]Lustra
- BZOJ3715 [PA2014]Lustra
- BZOJ3715: [PA2014]Lustra 水题
- 3715: [PA2014]Lustra|暴力
- BZOJ 3715: [PA2014]Lustra
- bzoj 3715: [PA2014]Lustra 乱搞
- 【BZOJ】【P3715】【PA2014】【Lustra】【题解】【水题】
- 【bzoj3713】【PA2014】【Iloczyn】【暴力】
- BZOJ 3713: [PA2014]Iloczyn|暴力
- 【PA2014】Fiolki
- bzoj3709 [PA2014]Bohater
- bzoj3713 [PA2014]Iloczyn
- 3709: [PA2014]Bohater
- 【BZOJ 3714】 [PA2014]Kuglarz
- [PA2014]Fiolki 解题报告
- 【PA2014】【BZOJ3709】Bohater
- bzoj3714【PA2014】Kuglarz
- tomcat 源码学习——准备工作
- qt5 槽的使用的简单例子(connect函数)
- Codeforces 486E. LIS of Sequence
- 微信小程序语音识别探索
- Java使用org.json.jar构造和解析Json数据
- bzoj3715 [PA2014]Lustra 暴力
- 关于Tomcat7启动闪退的解决办法
- 快速排序算法及JAVA实现
- shell基本命令
- TCP/IP分层模型
- 使用ajax与js查询后台数据
- R 多线程
- 微信服务器配置验证失败
- 统计学习(监督学习)框架总结