Weird append


the list is printed out to be [u'wer', u'no', u'ne'], with the extra u'' while wer, no, ne are the inputs. however the u is removed if i were to put hob = str(raw_input("What's your hobby?")) instead. why does this happen?? and also how can i remove the apostrophes in the list?

hobbies = []

for i in range(3):
    hob = raw_input("What's your hobby?")
print hobbies


please read this topic:

to get rid of the apostrophes in the list, use a for loop to print each item in list


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.