We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
Stream
Enum
1 parent bb028b9 commit 50619b1Copy full SHA for 50619b1
lib/elixir/lib/stream.ex
@@ -31,8 +31,11 @@ defmodule Stream do
31
Due to their laziness, streams are useful when working with large
32
(or even infinite) collections. When chaining many operations with `Enum`,
33
intermediate lists are created, while `Stream` creates a recipe of
34
- computations that are executed at a later moment. Let's see another
35
- example:
+ computations that are executed at a later moment. Then when the
+ stream is consumed later on, most commonly by using a function in
36
+ the `Enum` module, the stream will emit its elements one by one.
37
+
38
+ Let's see another example:
39
40
1..3
41
|> Enum.map(&IO.inspect(&1))
0 commit comments