MutDeque
Definitions
Returns an empty mutable deque with the given capacity rounded up to the default capacity.
Applies f to a start value s and all elements in d going from left to right.
That is, the result is of the form: f(...f(f(s, x1), x2)..., xn).
Returns the result of mapping each element and combining the results.
Applies f to a start value s and all elements in d going from right to left.
That is, the result is of the form: f(x1, ...f(xn-1, f(xn, s))...).
Apply the effectful function f to all the elements in the MutDeque d.
Apply the effectful function f to all the elements in the MutDeque d
along with that element's index.
Returns a range of all valid indices of the mutable deque d.
Returns an iterator over d.
Modifying d while using an iterator has undefined behavior and is dangerous.
Returns the concatenation of the string representation
of each element in d with sep inserted between each element.
Returns the concatenation of the string representation
of each element in d according to f with sep inserted between each element.
Optionally returns the back element. Does not remove it.
Optionally returns the front element. Does not remove it.
Returns Some(x) where x is the element at the back. Returns None if d is empty.
Returns Some(x) where x is the element at the front. Returns None if d is empty.
Returns true if MutDeques a and b have the same elements in the same order, i.e. are structurally equal.
Shuffles a copy of d using the Fisher–Yates shuffle.
Returns the sum of all elements in the deque d according to the function f.
Returns d as an array.
Returns a string representation of the given MutDeque d.