[issue1682] Move Demo/classes/Rat.py to Lib/fractions.py and fix it up.

Mark Dickinson report at bugs.python.org
Wed Jun 25 14:11:09 CEST 2008


Mark Dickinson <dickinsm at gmail.com> added the comment:

I'm reopening this to propose a last-minute minor change:

Can we remove the trailing 'L' from the numerator and denominator in
the repr of a Fraction instance?  E.g.,

>>> x = Fraction('9.876543210')
>>> x
Fraction(987654321L, 100000000L)
>>> x * (1/x)
Fraction(1L, 1L)

I'd rather see Fraction(987654321, 100000000) and Fraction(1, 1).  Does 
the 'L' serve any useful purpose?

----------
status: closed -> open

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue1682>
_______________________________________


More information about the Python-bugs-list mailing list