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????????

Posted by y05zh at 2006-08-17 14:28:35 on Problem 2924
#include<iostream.h>
#include<stdio.h>
#include<math.h>

int main()
{
	__int64 x,y;
	__int64 sum;
	int i,n;
	cin>>n; 
	for(i=0;i<n;i++)
	{       
		//int flag=0;
		

		scanf("%I64d%I64d",&x,&y);
		

		sum=(x+y)*(y-x+1)/2;
	//	if(flag==1)printf("-");
		printf("Scenario #%d:\n",i+1);

		printf("%I64d\n",sum);

		printf("\n");
	}
	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