| ||||||||||
| 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 | |||||||||
为什么wrong answer 呢?大家帮忙看看#include<stdio.h>
#include<string.h>
main()
{
long int i,n,k,j,t;
long int data[100000],que[100],ans[100];
char sep[5];
scanf("%ld",&n);
for(i=0;i<n;i++)
{
scanf("%ld",&data[i]);
}
scanf("%s",sep);
if(strcmp(sep,"###")==0)
{
scanf("%ld",&k);
for(i=0;i<k;i++)
{
scanf("%ld",&que[i]);
t=que[i];
ans[i]=data[t-1];
}
for(i=0;i<k;i++)
printf("%ld\n",ans[i]);
}
}
Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator