As it is summer now, I decided to learn a new language and Python was my choice. Really, what I would like to learn is how to manipulate Arabic text using Python. Now, I have found many many resources on using Python, which are really great. However, when I apply what I learned on Arabic strings, I get numbers and letters combined together.
Take for example this for English:
>>> ebook = 'The American English Dictionary'
>>> ebook[2]
'e'
Now, for Arabic:
>>> abook = 'القاموس العربي'
>>> abook[2]
'\xde' #the correct output should be 'ق'
However, using print
works fine, as in:
>>> print abook[2]
ق
What do I need to modify to get Python to always recognize Arabic letters?