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

Re:大家看看 怎么回事????????????????

Posted by tzj115 at 2007-08-07 23:09:08 on Problem 2153
In Reply To:大家看看 怎么回事???????????????? Posted by:tzj115 at 2007-08-07 23:08:14
> # include <stdio.h>
> # include <string.h>
> 
> char s[33];
> int cheng[52];
> 
> int main()
> {
> 	int N,M;
> 	int chengji=0;
> 	int nn;
> 	scanf("%d",&N);
> 	nn=N;
> 	while(nn--)
> 	{
> 		gets(s);
> 	}
> 	scanf("%d",&M);
> 	while(M--)
> 	{
> 		int count=0;
> 		int cc=1;
> 		int mark;
> 		while(count<N-1)
> 		{
> 			scanf("%d",&mark);
> 			getchar();
> 			gets(s);
> 			if(strcmp(s,"Li Ming")==0)
> 				chengji=mark;/////////////////////////////
> 			else
> 			{
> 				cheng[count]=mark;
> 				++count;
> 			}
> 		}
> 		for(int p=0;p<N-1;p++)
> 		{
> 			if(cheng[p]>chengji)
> 				++cc;
> 		}
> 		scanf("%d\n",cc);
> 	}
> 	return 0;
> }

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