Python Unicode 转换 字符串

estimate_price = "u00a340u00a0u00a0-u00a060"
sold_price = "Sold for u00a345"

转换代码:

 print type(estimate_price)
 print type(sold_price)

estimate_price = estimate_price.decode('unicode_escape')
sold_price = sold_price.decode('unicode_escape')

print estimate_price
print sold_price

输出结果是:

<type 'unicode'>
<type 'unicode'>
£40  - 60
Sold for £45
原文地址:https://www.cnblogs.com/xuchunlin/p/7247380.html