   @doc """
   Reverses the collection.
 
-  Expects an ordered collection.
-
   ## Examples
 
       Enum.reverse [1, 2, 3]
       #=> [3, 2, 1]
 
   """
+  @spec reverse(t), do: t
   def reverse(collection) when is_list(collection) do
     :lists.reverse(collection)
   end

  ## Examples

      Enum.map_join([1,2,3], &1 * 2)        #=> "246"
      Enum.map_join([1,2,3], &1 * 2, " = ") #=> "2 = 4 = 6"
      Enum.map_join([1,2,3], &1 * 2, ' = ') #=> '2 = 4 = 6'

  """
  def map_join(collection, joiner // "", mapper)

  def map_join(collection, joiner, mapper) when is_list(joiner) do

      #=> [4]

  """
  @spec filter_map(t, fun(element, do: boolean), fun(element, do: element)), do: t
  def filter_map(collection, filter, mapper) when is_list(collection) do
    lc item inlist collection, filter.(item), do: mapper.(item)
  end
