Search found 1 match

by Noel
Wed Jan 15, 2003 5:14 pm
Forum: Volume 1 (100-199)
Topic: 100 - The 3n + 1 problem
Replies: 1394
Views: 317984

100 Why? wrong answer!!?

Help! I can't find the problem?? thanks
[cpp]
/*@begin_of_source_code*/
#include<iostream>
using namespace std;
#define MAX 1000000
void main()
{
int i=0,j=0,temp,max;
while(1)
{
cin>>i>>j;
if(cin.eof() || cin.fail()) break;
if(i>MAX||j>MAX||i<=0||j<=0)
{
cerr<<endl;
break;
}
if(i>j ...

Go to advanced search