Problem with python

Peter J. Holzer hjp-python at hjp.at
Sat Sep 4 16:41:12 EDT 2021


On 2021-09-04 21:07:11 +0100, Rob Cliffe via Python-list wrote:
> Well, up to a point.
> In Python 2 the output from
>     print 1, 2
> is '1 2'
> In Python 3 if you add brackets:
>     print(1, 2)
> the output is the same.
> But if you transplant that syntax back into Python 2, the output from
>     print(1, 2)
> is '(1, 2)'.  The brackets have turned two separate items into a single
> tuple.

Yes. I was just talking about that specific case with a single function
call. I do not consider explaining the differences between Python 2 and
Python 3 to be time well spent in 2021, especially not to someone who
apparently just wants to report a bug to some unnamed project (whose
maintainers may or may not care about Python2 compatibility).

        hp

-- 
   _  | Peter J. Holzer    | Story must make more sense than reality.
|_|_) |                    |
| |   | hjp at hjp.at         |    -- Charles Stross, "Creative writing
__/   | http://www.hjp.at/ |       challenge!"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://mail.python.org/pipermail/python-list/attachments/20210904/b71f1548/attachment.sig>


More information about the Python-list mailing list