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

帮我看一下吧,实在没办法了:(近乎哀求)wa 掉了,但自以为思路清晰,并且应该AC

Posted by iowyh at 2005-07-29 23:13:37 on Problem 1922
#include <stdio.h>
#include<math.h>
void main()
{  int i,j,m,n;
	int t,temp;

  while(1){			
	scanf("%d",&i);
	if(i==0)  break;
	t=temp=0;
	
        for(j=0;j<i;j++)
	{  scanf("%d%d",&m,&n);
	    if(n>=0) { temp=ceil(4500.0*3600.0/(float)m/1000.0+(float)n);
	                    if(j==0)  t=temp;
                                 else	 t=temp>t?t:temp;
	              }
	}
	printf("%d\n",t);}}
	     

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