Cannot split a unicode string without converting to ascii - python 2.7
<p>I want to split the string <code>I have Â£300</code> but it seems that the split function first converts it to a ascii and after. But I can't convert it back to unicode the same as it was before. </p>

<p>Is there any other way to split such a unicode string without breaking it as in the snippet bellow.</p>

<pre><code># -*- coding: utf-8 -*-
mystring = 'I have Â£300.'
alist = mystring.split()
alist = [item.decode("utf-8") for item in alist]
print "alist",alist
print "mystring.split()",mystring.split()

#I want to get [I,have,Â£300]
#I get: ['I', 'have', '\xc2\xa3300.']
</code></pre>

<p>You are looking at a limitation of the way python 2 <em>displays</em> data.</p>

<p>Using python 2:</p>

<pre><code>&gt;&gt;&gt; mystring = 'I have Â£300.'
&gt;&gt;&gt; mystring.split()
['I', 'have', '\xc2\xa3300.']
</code></pre>

<p>But, observe that it will print as you want:</p>

<pre><code>&gt;&gt;&gt; print(mystring.split()[2])
Â£300.
</code></pre>

<p>Using python 3, by contrast, it displays as you would like:</p>

<pre><code>&gt;&gt;&gt; mystring = 'I have Â£300.'
&gt;&gt;&gt; mystring.split()
['I', 'have', 'Â£300.']
</code></pre>

<p>A major reason to use python 3 is its superior handling of unicode.</p>

python python-2.7 unicode split non-ascii-characters