Hi,
I was trying to create a default values map from a list. e.g.
if i have a list: ids = ["a", "b", "c"]
, then i want %{"a" => 0, "b" => 0, "c" => 0}
I did it but not sure if is the right way. Here is how I did it.
ids |> Enum.map(fn x -> {x, 0} end) |> Map.new()
Any better way to do this?