I have two list, just like


I want merge them and save to excel, as they have different dimention, so I want it have the following format.


and in the excel it will leave blank or fill some special words in the miss information position.

enter image description here


1 Answer 1


You can use Transpose + PadRight:

Transpose @ PadRight[{a,b}, Automatic, Null]

{{a1, b1}, {a2, b2}, {a3, b3}, {a4, b4}, {Null, b5}}


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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