Trouble getting loop to break

Dick Moores rdm at
Tue Nov 20 22:00:04 CET 2007

At 10:42 AM 11/20/2007, davisn90210 at wrote:
>Instead of comparing sum to the "known" value of e**x, why not test
>for convergence?  I.e., if sum == last_sum: break.  Seems like that
>would be more robust (you don't need to know the answer to computer
>the answer), since it seems like it should converge.

Yes! And believe it or not I did that before seeing your post. Works 
well. See <>

And also with the amazing Chudnovsky algorithm for pi. See 



More information about the Python-list mailing list