"S. Chris Colbert" <sccolbert at gmail.com> writes: > ....: print t Try replacing with: print "%0.20f" % t The thing you're missing is that floating point arithmetic isn't (in general) exact - but when it's printed it's rounded.