Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
c0d33ngr authored Feb 1, 2025
1 parent 2f63749 commit 4dfd35f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -1294,11 +1294,11 @@ val i: Unit < Any =

// Fold over stream elements
val j: Int < Any =
a.runFold(0)(_ + _)
a.fold(0)(_ + _)

// Process each element with side effects
val k: Unit < (IO & Abort[IOException]) =
a.runForeach(Console.printLine(_))
a.foreach(Console.printLine(_))
```

Streams can be combined with other effects, allowing for powerful and flexible data processing pipelines:
Expand Down

0 comments on commit 4dfd35f

Please sign in to comment.