I have a basic question about list-manipulation. I have two lists:

l1 = {{1, 1}, {2, 2}, {3, 3}}
l2 = {a, b, c}

The desired outcome is: {{a,1,1},{b,2,2},{c,3,3}}

I tried with Transpose but didn't get it to work; any suggestions?

MapThread[Prepend, {l1, l2}]


Flatten /@ Transpose[{l1, l2}]
| improve this answer | |

Not the answer you're looking for? Browse other questions tagged or ask your own question.