Bug or feature: double strings as one

durumdara durumdara at gmail.com
Fri Aug 7 08:31:10 EDT 2009


Hi!

I found an interesting thing in Python.
Today one of my "def"s got wrong result.

When I checked the code I saw that I miss a "," from the list.

l = ['ó' 'Ó']

Interesting, that Python handle them as one string.

print ['ó' 'Ó']
['\xf3\xd3']

I wanna ask that is a bug or is it a feature?

In other languages, like Delphi (Pascal), Javascript, SQL, etc., I
must concatenate the strings with some sign, like "+" or "||".

This technic is avoid the mistyping, like today. But in python I can
miss the concat sign, and I got wrong result...

Thanks for your help and for your answer:
   dd





More information about the Python-list mailing list