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

为什么老说是presentation error 大虾们帮帮忙!!

Posted by cpp051000448166 at 2005-04-02 18:17:48 on Problem 1663
#include <iostream.h>
int n;
long int x,y;
void main()
{
	cin>>n;
	for(int i=0;i<n;i++)
	{
		cin>>x>>y;
		if(x!=y&&(x-2)!=y)
			cout<<"No Number"<<endl;
		else
			if(x%2==0)
				cout<<x+y<<endl;
			else
				if(x%2==1)
					cout<<x+y-1;
	}
}
				

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