On Sun, Aug 28, 2016 at 11:37:00AM +0100, Paul Moore wrote: > And if you're concerned about larger numbers, such as 16000000000, and > the need to count zeroes, I'd argue that you should name such a > constant - and Python 3.6 will allow you to write it as 16_000_000_000 > in any case, making things completely clear.
Since we're talking about integers, you can write 16*10**9 and the keyhole optimizer in recent versions of Python will do the maths for you at compile-time. Or just write 16e9 and use a float. By the way, I see at least one language (Frink) uses EE for exact integer exponents: 16e9 => float 16.0*1.0**9 16ee9 => int 16*10**9 Anyone think this is a good idea? -- Steve _______________________________________________ Python-ideas mailing list Python-ideas@python.org https://mail.python.org/mailman/listinfo/python-ideas Code of Conduct: http://python.org/psf/codeofconduct/