Skip to content

Instantly share code, notes, and snippets.

/.py

Created June 8, 2016 08:15
Show Gist options
  • Save anonymous/23cfef0d5034cd5907b59990e3406ae5 to your computer and use it in GitHub Desktop.
Save anonymous/23cfef0d5034cd5907b59990e3406ae5 to your computer and use it in GitHub Desktop.
def vake(list_of_keys,list_of_values):
if len(list_of_values) >= len(list_of_keys):
return {x[0]:x[1] for x in zip(list_of_keys,list_of_values)}
else:
list_of_values = list_of_values + [None]*(len(list_of_keys) - len(list_of_values))
return {x[0]:x[1] for x in zip(list_of_keys,list_of_values)}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment