[issue39641] concatenation of Tuples
Ammar Askar
report at bugs.python.org
Sat Feb 15 18:31:23 EST 2020
Ammar Askar <ammar at ammaraskar.com> added the comment:
Are you trying to concatenate a single string? If so keep in mind you need a trailing comma:
>>> (1, 2) + (3, 4) + ('a',)
(1, 2, 3, 4, 'a')
>>> (1, 2) + (3, 4) + ('a')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: can only concatenate tuple (not "str") to tuple
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue39641>
_______________________________________
More information about the Python-bugs-list
mailing list