We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Input
tuple([1])
Expected output:
(1)
However, I got this:
(1,)
But for multiple element list convert to tuple is working fine.
3.9, 3.10, 3.11
Linux, macOS, Windows
The text was updated successfully, but these errors were encountered:
Sorry, but why you expect this output?! One-element tuples covered in many places of CPython docs, including the tutorial: https://docs.python.org/3/tutorial/datastructures.html#tuples-and-sequences
Sorry, something went wrong.
Except for an empty tuple (()), commas, not parentheses, define a tuple, with 1 element tuple requiring a trailing comma.
()
No branches or pull requests
Bug report
Bug description:
Input
Expected output:
(1)
However, I got this:
(1,)
But for multiple element list convert to tuple is working fine.
CPython versions tested on:
3.9, 3.10, 3.11
Operating systems tested on:
Linux, macOS, Windows
The text was updated successfully, but these errors were encountered: