| ||||||||||
| 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 | |||||||||
哪位大神帮我看看啊,这到底错哪了啊#include <stdio.h>
int main()
{
long n,time=-1,v,i,t;
double q;
scanf("%d",&n);
while (n!=0)
{
for (i=0;i<n;i++)
{
scanf("%d%d",&v,&t);
if (t>=0)
{
q=ceil(t+4.5*3600.0/v);
if ((time>q)||(time==-1))
time=q;
}
}
printf("%d\n",time);
scanf("%d",&n);
time=-1;
}
return 0;
}
Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator