I’m currently working on a script that’ll be working with Youtubes API. I’m still learning how to correctly parse using Python, but am a little lost on what method to take for something like this.
I have this string:
[{'term': u'Video Blogging', 'scheme': None, 'label': None}, {'term': u'blogging', 'scheme': None, 'label': None}, {'term': u'stuff', 'scheme': None, 'label': None}, {'term': u'Videos', 'scheme': None, 'label': None}]
I need to take that, and turn it in to this:
Video Blogging, blogging, stuff, Videos
What would be the best approach to solve this? Any help is appreciated, thanks!
and if you want to get the items as a comma-delimited string, use:
I used
a.get('term')instead ofa['term']to avoid aKeyErrorfor items without atermkey.