Rough draft: Proposed format specifier for a thousands separator

Tim Rowe digitig at gmail.com
Fri Mar 13 12:05:09 EDT 2009


2009/3/13  <pruebauno at latinmail.com>:
> I think this proposal is more for debugging big numbers and meant mostly
> for programmers' eyes. We are already using the dot instead of comma
> decimal separator in our programming languages that one more
> Americanism won't kill us.

If it were for the programmers' eyes then it would be in the code, not
in the formatted output. Debugging of big numbers can be done by
checking within code, so there's no need to let this escape to the
output.

And if it's for programmers' eyes then the statement "The COMMA is
used when a PERIOD is the decimal separator" is wrong, at least if it
means that the COMMA is the /only/ separator used when a PERIOD is the
decimal separator. Ada uses UNDERSCOREs, which can be placed almost
anywhere in a numeric literal and are ignored.

And if it's mostly for programmers' eyes, why does the motivation
state that "Adding thousands separators is one of the simplest ways to
improve the professional appearance and readability of output exposed
to end users"? The proposal is clearly for the presentation of numbers
to end users, and quite simply is an encouragement to sloppiness in
presenting those numbers. If "Finance users and non-professional
programmers find the locale approach to be frustrating, arcane and
non-obvious" then by all means propose a way of making it simpler and
clearer, but not a bodge that will increase the amount of bad software
in the world.

-1 for all of the proposals.
-- 
Tim Rowe



More information about the Python-list mailing list