> Writing code is primarily for *human readers*. Once you've compiled the 
> code once, the computer never need look at it again, but human being come 
> back to read it over and over again, to learn from it, or for 
> maintenance. We rightfully value our own time and convenience as more 
> valuable than that of the computer's, which is why we use programming 
> languages at all, instead of having custom-made hardware built for every 
> task we want the computer to do: 

Not only the code itself, but, hopefully, embedded comments help even 
non-authors of the code to understand, maintain and improve it. Programming 
books that include examples often spend many pages dissecting even short 
segments of the code to tutor would-be developers how it works and what it 
does. Well written code in any language, with accompanying comments, is 
invaluable for anyone who has the need or interest to Understand and maintain 
it.

My (ancient) books about object-oriented programming were used to teach 
hundreds of computer science students in universities all over the world, and 
the stressed the importance of embedded comments.

How many times has any programmer looked at (even inscrutable) code with 
accompanying comments and hasn't said to themselves "so that's how to do it, or 
that's what it does".

It's time to stop having flame wars about languages and embrace programmers who 
care enough about possible future readers of their code to thoroughly comment 
it. Comments are far more valuable than the actual language in which the code 
is written, IMHO.

Sent from my iPad.


-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to