You can download this code by clicking the button below.
This code is now available for download.
The function merges multiple iterable objects into an iterator. If one of the iterable objects is shorter, it fills the remaining positions with fillvalue.
Technology Stack : zip_longest, iterable objects, fillvalue
Code Type : Function
Code Difficulty : Intermediate
def zip_longest(*args, fillvalue=None):
zip_longest = zip_longest(*args, fillvalue=fillvalue)
return [tuple(x) for x in zip_longest]