Copyright | (C) 2012-16 Edward Kmett |
---|---|
License | BSD-style (see the file LICENSE) |
Maintainer | Edward Kmett <ekmett@gmail.com> |
Stability | experimental |
Portability | non-portable |
Safe Haskell | None |
Language | Haskell98 |
This module is designed to be imported qualified.
Documentation
A Banker's deque based on Chris Okasaki's "Purely Functional Data Structures"
Monad Deque Source # | |
Functor Deque Source # | |
Applicative Deque Source # | |
Foldable Deque Source # | |
Traversable Deque Source # | |
Alternative Deque Source # | |
MonadPlus Deque Source # | |
Plus Deque Source # | |
Alt Deque Source # | |
Apply Deque Source # | |
Bind Deque Source # | |
TraversableWithIndex Int Deque Source # | |
FoldableWithIndex Int Deque Source # | |
FunctorWithIndex Int Deque Source # | |
Eq a => Eq (Deque a) Source # | |
Ord a => Ord (Deque a) Source # | |
Show a => Show (Deque a) Source # | |
Semigroup (Deque a) Source # | |
Monoid (Deque a) Source # | |
Reversing (Deque a) Source # | |
Snoc (Deque a) (Deque b) a b Source # | |
Cons (Deque a) (Deque b) a b Source # | |
fromList :: [a] -> Deque a Source #
O(n) amortized. Construct a Deque
from a list of values.
>>>
fromList [1,2]
BD 1 [1] 1 [2]