| ||||||||||
| Online Judge | Problem Set | Authors | Online Contests | User | ||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest | |||||||||
求救啊,为什么是RE.......#include<cstdio>
#define N 1000
int main()
{
__int64 cases;
__int64 a[N],b[N],n[N],sum[N]={0};
__int64 l[N][N]={0},r[N][N]={0};
scanf("%I64d",&cases);
for(int k=0;k<cases;k++){
scanf("%I64d %I64d %I64d",&a[k],&b[k],&n[k]);
for(int i=0;i<n[k];i++)
{
scanf("%I64d %I64d",&l[k][i],&r[k][i]);
}
}
for(int k=0;k<cases;k++){
for(int i=1;l[k][i]!=0;i++)
{
for(int j=0;j<i;j++)
{
if(r[k][i]<r[k][j]&&l[k][i]>l[k][j])sum[k]++;
}
}
}
for(int i=0;i<cases;i++)
printf("%I64d\n",sum[i]);
}
数组都1000了,还RE呀?...............
Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator