Arrays & Iterables

Zip Arrays into Tuples

easyJS SpecificJS / TS3 tests

Problem Statement

Implement `zip(...arrays)` that groups elements from each array at their respective index into tuples. The length of the returned array matches the shortest input array.

Examples

Example 1:
zip(['a', 'b'], [1, 2], [true, false]); // [['a', 1, true], ['b', 2, false]]
JavaScript & TypeScript starter code included
Run this as a live interview

Practice solo

3 test cases. No second person needed.

Get new interview exercises

Practice problems and review drills, sent when we publish new ones. No spam.

Unsubscribe anytime. We never share your address.