I am using python 3, and don't understand why the output has b in each start of the line. I don't think this is the case for python 2. Why is this and how to remove it? Thanks
import urllib
# fhand = urllib.urlopen('http://www.py4inf.com/code/romeo.txt') in Python 2
fhand = urllib.request.urlopen('http://www.py4inf.com/code/romeo.txt')
for line in fhand:
print(line.strip())
output looks like this
b'But soft what light through yonder window breaks'
b'It is the east and Juliet is the sun'
b'Arise fair sun and kill the envious moon'
b'Who is already sick and pale with grief'