object Collections
Ordering
- Alphabetic
- By Inheritance
Inherited
- Collections
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- Protected
Deprecated Value Members
- def unfoldLeft[A, B](seed: B)(f: (B) => Option[(B, A)]): Seq[A]
Produces a Seq from a seed and a function.
Produces a Seq from a seed and a function.
Example, produces a List from 100 to 0.
unfoldLeft(0) { case a if a > 100 => None case a => Some((a + 1, a)) }
- A
Type of the final List elements.
- B
Seed type
- seed
Initial value.
- f
Function producing the List elements.
- Annotations
- @deprecated
- Deprecated
(Since version 2.9.0) use Seq.unfold
Utilities functions for Collections