Skip to content

Instantly share code, notes, and snippets.

@lfborjas
Created October 22, 2012 20:05
Show Gist options
  • Save lfborjas/3933764 to your computer and use it in GitHub Desktop.
Save lfborjas/3933764 to your computer and use it in GitHub Desktop.
dicts that can merge in python
class hash: pass
hash.merge = lambda self, **b: dict(self.items() + b.items())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment