Last active
July 21, 2018 21:50
-
-
Save vinaykudari/52158d0b35d75894fa11359df14dccc2 to your computer and use it in GitHub Desktop.
zip function
This file contains hidden or 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
list_a = [1, 2, 3, 4, 5] | |
list_b = ['a', 'b', 'c', 'd', 'e'] | |
zipped_object = zip(list_a, list_b) | |
>> type(zipped_object) | |
<class 'zip'> | |
>> list(zipped_object) | |
[(1, 'a'), (2, 'b'), (3, 'c'), (4, 'd'), (5, 'e')] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment