How can I convert tuple of dictionaries like example present below:
({(1, 2): 3},
{(1, 3): 5},
{(1, 4): 5},
{(2, 4): 5},
{(1, 5): 10},
{(2, 6): 9},
{(1
>>> a=({(1, 2): 3},
{(1, 3): 5},
{(1, 4): 5},
{(2, 4): 5},
{(1, 5): 10},
{(2, 6): 9},
{(1, 6): 9},
{(2, 1): 2},
{(2, 2): 3},
{(2, 3): 5},
{(2, 5): 10},
{(1, 1): 2})
>>> {key: x[key] for x in a for key in x}
{(1, 2): 3, (2, 6): 9, (1, 4): 5, (1, 1): 2, (1, 5): 10, (1, 3): 5, (1, 6): 9, (2, 1): 2, (2, 2): 3, (2, 3): 5, (2, 5): 10, (2, 4): 5}
>>>