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

我用1.6180339887498948482过了

Posted by oipn4e2 at 2008-07-02 22:21:52 on Problem 1067
In Reply To:各位大牛小牛,帮忙看下一个很诡异的问题 Posted by:drift_ice at 2007-04-17 21:03:06
我的过了:

#include <cstdio>
int main(){
    long a,b;
    while(2==scanf("%ld %ld",&a,&b)){
        if(a>b){a^=b;b^=a;a^=b;}
        if(a==long((b-a)*1.6180339887498948482))
            printf("0\n");
        else
            printf("1\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