Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The function doesn't look to be tail-recursive, so my guess would be a stack overflow.

Of course, if you run it and get a stack overflow, you have no way of knowing whether the number was really a counterexample or just one that took many steps to reach 1.



It would be a stack overflow, except Racket does not stack overflow--it will grab more memory, make a bigger stack, and continue. Eventually your problem would be "out of memory".


Of course, though it does mean you should examine it further to check.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: