I am new to python and I am getting something weird stuff in my python console while displaying output into the screen.
>>> macbeth_sentsence = gutenberg.sents('shakespeare-macbeth.txt');
>>> macbeth_sentsence
[[u'[', u'The', u'Tragedie', u'of', u'Macbeth', u'by', u'William', u'Shakespeare', u'1603', u']'], [u'Actus', u'Primus', u'.'], ...]
I am not expecting the extra 'u' character in my output screen.
Anyone knows how to suppress that? Anything to do with default python settings?
UPDATED from BELOW: for people who didn't understood what I want to resolve.
When the same command was executed in my Windows system in Vbox
I got something like this:
>>> macbeth_sentsence = gutenberg.sents('shakespeare-macbeth.txt');
>>> macbeth_sentsence
[['[', 'The', 'Tragedie', 'of', 'Macbeth', 'by', 'William', 'Shakespeare', '1603', ']'], ['Actus', 'Primus', '.'], ...]
I want the same result in my Mac machine; what adjustment I have to do into my defaults to get result like that I got in Windows.
PS: Answers from this: removing `u` character in python output and this: Python ascii utf unicode and this : Python string prints as [u'String'] are not what I am looking for.