Dear Norman, I would propose:
ret = {}
myvalues = []
responses = [{'a1': [1], 'a2': [1, 2, 3]}, {'a1': [0], 'a2': [0, 1, 3]}]
for response in responses:
for answer in response.items()
ret.setdefault(response[0], []).append(response[1])
Regards,
Benoit Thiell.
_______________________________________________
Tutor maillist - [email protected]
http://mail.python.org/mailman/listinfo/tutor
