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

请教

Posted by scandrive at 2004-12-11 01:10:09 on Problem 2017
#include<stdio.h>
void main()
{
	int i,n,a[10],b[10],x,s;
	scanf("%d",&n);
		while(n>=1&&n<=10)
		{
			for(i=1;i<=n;i++)
				scanf("%d %d",&a[i],&b[i]);
			for(b[0]=0,i--,s=0;i>0;i--)
			{
				x=a[i]*(b[i]-b[i-1]);
				s=s+x;
			}
			printf("%d miles\n",s);
			scanf("%d",&n);
		}
}


显示:Runtime Error 不明白了…………
可以 教教我吗?

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