[New-bugs-announce] [issue41518] incorrect printing behavior with parenthesis symbols
Ramesh Sahoo
report at bugs.python.org
Mon Aug 10 14:56:50 EDT 2020
New submission from Ramesh Sahoo <rameshsahoo11 at gmail.com>:
With for loop, I am able to print all elements in the list 'a'
a = ['a','a','b','b','c']
for i in a:
print(i)
O/P:
a
a
b
b
c
but with the following loop, python only prints 3 uniq elements instead of 5.
stack = ['(', '(', '[', ']', ')']
for i in stack:
print(i)
O/P:
(
]
)
Is this is intended behavior?
----------
messages: 375136
nosy: rameshsahoo11
priority: normal
severity: normal
status: open
title: incorrect printing behavior with parenthesis symbols
type: behavior
versions: Python 3.6
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue41518>
_______________________________________
More information about the New-bugs-announce
mailing list