I have the following dataframe.
a1 = [1,2,3]
a2 = [[[11,'a'],[12, 'b'],[13,'c']], [[21,'a'],[22, 'a']], [[31, 'b']]]
df = pd.DataFrame({'col1': a1,
'col2': a2})
col1 col2
0 1 [[11, a], [12, b], [13, c]]
1 2 [[21, a], [22, a]]
2 3 [[31, b]]
And I want to convert it to this dataframe
c1 c2 c3
1 11 a
1 12 b
1 13 c
2 21 a
2 22 a
3 31 b
Could anyone show me how to do that. Many thanks.