Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

My code 交着玩的 ^_^ int main(){int t,n,c,ji,ou,i;scanf("%d",&t);while(t--){scanf("%d",&n);for(i=0,ji=0,ou=0;i<n;i++){scanf("%d",&c);if(c==1){if(i%2==0) ou++;else ji++;}}i=ou-ji;if(n%2){printf("YES\n"

Posted by oeym at 2006-03-07 23:12:50 on Problem 1063
In Reply To:大牛们,帮忙呀! 我实在不知道哪里错了 Posted by:caisiren at 2006-03-07 23:09:20
> 如果是奇数,那么一定是‘YES’
> 如果是偶数,则统计在奇数位上和偶数位上白棋的个数,如果他们相差小于2,那么也一定是'YES'
> 这难道不对吗?
> 

Followed by:

Post your reply here:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator