I have a list of the following format
list=[OrderedDict([('Component', 'AAAA')]), OrderedDict([('Component', 'BBBB')])]
How do extract the values 'AAAA' and 'BBBB' to make them into a new list?
I have a list of the following format
list=[OrderedDict([('Component', 'AAAA')]), OrderedDict([('Component', 'BBBB')])]
How do extract the values 'AAAA' and 'BBBB' to make them into a new list?
Try:
[i['Component'] for i in list]