Skip to content

Instantly share code, notes, and snippets.

@nattybear
Last active December 9, 2018 13:40
Show Gist options
  • Save nattybear/df6d7dfdacb588c271857a6219f9c914 to your computer and use it in GitHub Desktop.
Save nattybear/df6d7dfdacb588c271857a6219f9c914 to your computer and use it in GitHub Desktop.
def zip(xs, ys):
x, y = map(len, [xs, ys])
z = x if x < y else y
return [(xs[i], ys[i]) for i in range(z)]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment