Enum.frequencies/1

defmodule Enum do
  def frequencies(enumerable)
end

Returns a map with keys as unique elements of enumerable and values as the count of every element.