Created
April 15, 2016 10:58
-
-
Save f5io/d4b217c610ee5bc78b71ac9f70361f3a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const zip = (arr, length = 2) => | |
Array.from({ length }, (_, i) => | |
arr.filter((_, j) => | |
j % length === i)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment