Const in python?

David Brown david at no.westcontrol.spam.com
Wed Mar 26 04:24:25 EST 2003


"Lulu of the Lotus-Eaters" <mertz at gnosis.cx> wrote in message
news:mailman.1048613681.19759.python-list at python.org...
> Dave Brueck <dave at pythonapocrypha.com> wrote previously:
> |> ALL CAPS conventions - they look ugly,
>
> |To you, perhaps. This is a very widely used, understood, and accepted
> |convention - I quite like it.
>
> As if this were a democracy, I'll just chime in "I agree" :-).  Brueck
> does a great job of explaining exactly why capitalized contstants aid
> comprehension.

He did indeed give a good explaination.  I don't like all caps personally,
but I fully realise that I'm in the minority.

>
> Maybe I'm tainted by having already used it in a dozen languages before
> Python... hmmm, do you think there is a reason those dozen languages all
> use the same convention?
>

Perhaps because it's conventional?  People are used to it, so there is no
point in changing it without good reason.  The use of all caps in
programming stems back to the days when caps were all you had.  I feel that
it looks ugly, and I am not going to use it just to be traditional.  If
people (such as Dave Brueck) feel it improves the readability of their
programs, then that's great.  I think it is important to emphasis
readability in programming, and that readability is more important than
writing code just like your grandfather wrote it, so I dislike the idea of
using all caps just because it has been done in dozens of other langauges
(after all, curly brackets and begin-ends are used to show scope in dozens
of other languages - that doesn't make it the only way to do it :-).  But I
have no problem with using all caps because you feel it really is a better
way to do it.

David.


> Yours, Lulu...
>
> --
>  mertz@  _/_/_/_/ THIS MESSAGE WAS BROUGHT TO YOU BY: \_\_\_\_    n o
> gnosis  _/_/             Postmodern Enterprises            \_\_
> .cx    _/_/                                                 \_\_  d o
>       _/_/_/ IN A WORLD W/O WALLS, THERE WOULD BE NO GATES \_\_\_ z e
>
>






More information about the Python-list mailing list