79756782

Date: 2025-09-05 12:44:31
Score: 0.5
Natty:
Report link

Using Enum.reduce/3 works as well:

map = %{
  "US" => "United States",
  "CA" => "Canada",
  "NL" => "The Netherlands"
}
Enum.reduce(map, %{}, fn {k, v}, acc ->
  Map.put(acc, v, k)
end)
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: canelle