print , (was Re: Python vs. Perl, which is better to learn?)

Donn Cave donn at u.washington.edu
Fri May 3 12:18:27 EDT 2002


Quoth Alex Martelli <aleax at aleax.it>:
...
| I find Python's print convenient for debugging purposes, and that's
| about all.  No matter how refined the theoretical possibilities, some
| of us dinosaurs, at times, feel most comfortable rapidly sticking print
| statements at strategic points in the code to follow the control flow
| and data values, then commenting some of them out again, and so
| on.  For this purpose, print's "convenience" features are just fine --
| they save me a fraction of a second each time wrt explicitly using
| blanks, str calls, etc, or a formatstring.

If it had been intended primarily for diagnostic purposes, then it
should have been made to write to the diagnostic stream (stderr)
by default.  Then the diagnostic output wouldn't interfere with
normal use of the regular output, as normal redirection to a file
or pipe would involve only the latter.

	Donn Cave, donn at u.washington.edu



More information about the Python-list mailing list