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:这么简单的题目怎么会WA呢 :(In Reply To:这么简单的题目怎么会WA呢 :( Posted by:mjmj at 2004-11-25 16:35:23 #include <stdio.h> #include <stdlib.h> #include <iostream> using namespace std; char arr[15][30]; void main() { int n; int n2; int i; int t=1; char temp[30]; while(1) { cin>>n; if(n==0) break; cout<<"SET: "<<t++<<endl; n2=n/2; for(i=0;i<n2;i++) { cin>>temp; cout<<temp<<endl; cin>>arr[i]; } if(n%2) { cin>>temp; cout<<temp<<endl; } for(i=n2-1;i>=0;i--) cout<<arr[i]<<endl; } } > 有没有奇怪点的测试数据? Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator