On 9/1/05, Barry Warsaw <[EMAIL PROTECTED]> wrote:
> On Thu, 2005-09-01 at 10:58, Guido van Rossum wrote:
> 
> > [Reinhold Birkenfeld]
> > > You'd have to enclose print arguments in parentheses. Of course, the 
> > > "trailing
> > > comma" form would be lost.
> >
> > And good riddance! The print statement harks back to ABC and even
> > (unvisual) Basic. Out with it!
> 
> I have to strongly disagree.  The print statement is simple, easy to
> understand, and easy to use.

I agree with Barry. In particular, the behaviour of adding spaces
between items is something I find very useful, and it's missing from
the functional forms.

    print greeting, name

feels much more natural to me than

    write(greeting, " ", name)
or
    writef("%s %s", greeting, name)

And that's even worse if the original used a literal "Hello", and only
later migrated to a variable greeting - remembering to get the spaces
in the right place is a pain:

    print "Hello", name  ==> print greeting, name
    write("Hello ", name) ==> write(greeting, name) # oops, forgot the space
or                               write(greeting, " ", name) #
non-obvious translation

OK, it's a minor thing, but what's the benefit?

I've used print functions a lot in things like VBScript and
Javascript, and hated them every time...

Paul.
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to