tag:blogger.com,1999:blog-6949071374236376494.post5023922539843283532..comments2017-10-04T03:47:48.367-07:00Comments on Adventures of a Wannabe Programmer: Collatz Sequence: Euler 14 Problem Walkthrough in Pythonnewb_girlhttp://www.blogger.com/profile/11799250193629201408noreply@blogger.comBlogger1125tag:blogger.com,1999:blog-6949071374236376494.post-47971408450614004552015-06-12T00:29:04.963-07:002015-06-12T00:29:04.963-07:003*n+1 where n is odd is always going to have an ev...3*n+1 where n is odd is always going to have an even result, so you can do this:<br />return 2 + recursive_method((3*n + 1) / 2)<br />it doesn't change the general scaling of the performance but it does provide a non trivial boostTolomeahttps://www.blogger.com/profile/16384928311920896699noreply@blogger.com