| ||||||||||
| Online Judge | Problem Set | Authors | Online Contests | User | ||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest | |||||||||
我每次提交1067都说我Output Limit Exceed,我检查不出来,能帮忙看看吗?#include<iostream>
using namespace std;
int main()
{
long i, j;
long min, max;
cin>>i>>j;
while(i >= 0 && j>=0)
{
max = (i>j)?i:j;
min = (i>j)?j:i;
if(max == min || min == 0)
{
cout<<1<<endl;
goto step;
}
if(max != int(min*1.618+1))
{
cout<<1<<endl;
goto step;
}
if(min == int((max - min)*1.618))
cout<<0<<endl;
else
cout<<1<<endl;
step: cin>>i>>j;
}
return 0;
}
Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator