Returns true if there are no elements in this collection.
Concatenates this with c
in O(1) runtime.
Alias for cons.
Alias for snoc.
collect B
from this for which f
is defined *
Returns a new catenable consisting of a
followed by this.
Returns a new catenable consisting of a
followed by this. O(1) runtime.
Yields to Some(a, Catenable[A]) with a
removed where f
holds for the first time,
otherwise yields None, if a
was not found
Traverses only until a
is found.
Applies the supplied function to each element and returns a new catenable from the concatenated results
Folds over the elements from left to right using the supplied initial value and function.
Applies the supplied function to each element, left to right.
Applies the supplied function to each element and returns a new catenable.
Returns false if there are no elements in this collection.
Returns a new catenable consisting of this followed by a
.
Returns a new catenable consisting of this followed by a
. O(1) runtime.
Converts to a list.
Converts to a vector.
Returns the head and tail of this catenable if non empty, none otherwise.
Returns the head and tail of this catenable if non empty, none otherwise. Amortized O(1).
Trivial catenable sequence. Supports O(1) append, and (amortized) O(1)
uncons
, such that walking the sequence via N successiveuncons
steps takes O(N). Like a difference list, conversion to aSeq[A]
takes linear time, regardless of how the sequence is built up.