I have an array like this
Address=['fâch','Pyrénées']
print(Address)
Here array has the special character.How can I solve this
error: utf8' codec can't decode byte 0xe1 in position 0: invalid continuation byte
I have an array like this
Address=['fâch','Pyrénées']
print(Address)
Here array has the special character.How can I solve this
error: utf8' codec can't decode byte 0xe1 in position 0: invalid continuation byte
Just try this in python2.7 :
# -*- coding: utf-8 -*-
Address = ['fâch', 'Pyrénées']
for i in Address:
print i
The commented line should be in top of the file.
You can use like this:
Address=['fâch','Pyrénées']
for i in Address:
value = unicode(i, 'utf-8')
print value
This should help.