published: 29th of January 2021
Maps are used to store key/value pairs. Maps are defined with curly brackets prefixed with a percent %{} .
# Define a map
map = %{stuff: "stuff", things: "things"}
# Define a map with the hash rocket syntax
map = %{:stuff => "stuff", :things => "things"}
# Create a map from a list of tuples
map = Map.new([{:stuff, "stuff"}, {:things, "things"}])
https://elixir-lang.org/crash-course.html#maps
https://elixir-lang.org/getting-started/keywords-and-maps.html
https://learning.oreilly.com/library/view/elixir-in-action/9781617295027/c02.xhtml