without using decimal module: >>> x = 2000000000000034 >>> print('%d'%(x/2)) 1000000000000017
On Thu, Jul 1, 2010 at 13:56, Richard D. Moores <rdmoo...@gmail.com> wrote: >>>> x = 2000000000000034 >>>> x/2 > 1000000000000017.0 >>>> print(x/2) > 1e+15 > > I was expecting, in fact needing, 1000000000000000017 or 1000000000000000017.0 > > 1e+15 is unsatisfactory. Am I forced to use the decimal module? > > Dick Moores > _______________________________________________ > Tutor maillist - tu...@python.org > To unsubscribe or change subscription options: > http://mail.python.org/mailman/listinfo/tutor > _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor