Skip to content

Instantly share code, notes, and snippets.

@Adzz
Last active June 16, 2019 15:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Adzz/853484e5f526e58cf74b75c2b1153917 to your computer and use it in GitHub Desktop.
Save Adzz/853484e5f526e58cf74b75c2b1153917 to your computer and use it in GitHub Desktop.
map_1 = %{first: 1, second: 2}
map_2 = %{first: 3, second: 4}
# These just work! 🤩
Zip.apply(map_1, map_2, Add) #=> %{first: 4, second: 6}
Zip.apply(map_1, map_2, Subtract) #=> %{first: 4, second: 6}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment