Stream.flat_map/2

defmodule Stream do
  def flat_map(stream, fun)
end

Maps the given fun over enumerable and flattens the result.

This function returns a new stream built by appending the result of invoking fun on each element of enumerable together.