python3: 'where' keyword
Paul Rubin
http
Mon Jan 10 06:19:05 EST 2005
"Carl Banks" <invalidemail at aerojockey.com> writes:
> > So do you approve of the movement to get rid of the print statement?
>
> Any little incremental change in Python you could make by having or not
> having a print statement would be minor compared to the H-Bomb of
> ugliness we'd get if suites of statements were to be allowed inside
> Python expressions. Having or not having a print statement might
> violate some small aspect of the Zen, but it won't rape the whole list.
How about macros? Some pretty horrible things have been done in C
programs with the C preprocessor. But there's a movememnt afloat to
add hygienic macros to Python. Got any thoughts about that?
> So I don't know what point you're trying to make.
Why should you care whether the output of a macro is ugly or not,
if no human is ever going to look at it?
> But to answer your question, I would prefer a Python without a print
> statement, since a print method could do anything the print statement
> could.
A print -method-?!! You /really/ want to say
your_name = "Carl"
your_favorite_cereal = "cornflakes"
("Hi", your_name, "how about a nice bowl of", your_favorite_cereal).print()
instead of
your_name = "Carl"
your_favorite_cereal = "cornflakes"
print "Hi", your_name, "how about a nice bowl of", your_favorite_cereal
????
I've heard of people wanting to replace print with a function, but
hadn't heard of replacing it with a method. Are you trying to turn
Python into Ruby?
More information about the Python-list
mailing list