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

Re:需要数组吗?、、庆祝自己刷了130道水题、、几行解决、、

Posted by wxfwxf328 at 2012-02-06 09:24:04 on Problem 1663
In Reply To:需要数组吗?、、庆祝自己刷了130道水题、、几行解决、、 Posted by:734330469 at 2011-07-29 23:38:04
#include<iostream>
using namespace std;
int main()
{
    int t,x,y;
    cin>>t;
    while(t--)
    {
        cin>>x>>y;
        if(x==y||x==y+2) cout<<x+y-(x&1)<<endl;
        else cout<<"No Number"<<endl;
    }
    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