Created
April 15, 2019 19:48
-
-
Save Aekschen/c51b50eee53806ce73e22f96d0ac6c1f to your computer and use it in GitHub Desktop.
Python zip
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
| # Why Python Is Great: # Function argument unpacking def myfunc(x, y, z): print(x, y, z) tuple_vec = (1, 0, 1) dict_vec = {'x': 1, 'y': 0, 'z': 1} >>> myfunc(*tuple_vec) 1, 0, 1 >>> myfunc(**dict_vec) 1, 0, 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment