Skip to content
UPEEC

zip()

Pairs up items from several iterables, stopping at the shortest (use strict=True to require equal lengths).

Beginner
Comments 0
for name, ohms in zip(names, values, strict=True):
    print(name, ohms)

Spotted a mistake or want to add detail? Suggest an improvement — Content Contributors' edits are reviewed by editors before they go live.

Discussion (0)

Sign in or join free to ask questions and discuss this topic.