-
Effekt Library
- dequeue
- Dequeue
- emptyQueue
- isEmpty
- size
- first
- last
- check
- pushFront
- popFront
- pushBack
- popBack
- show
- show
- show
- show
- show
- println
- println
- println
- println
- dequeue Jump to source: libraries/common/dequeue.effekt
- Dequeue
[R] (front: List[R], frontSize: Int, rear: List[R], rearSize: Int) - emptyQueue
[R]: Dequeue[R] / {} - isEmpty
[R] (dq: Dequeue[R]): Bool / {} - size
[R] (dq: Dequeue[R]): Int / {} - first
[R] (dq: Dequeue[R]): Option[R] / {} - last
[R] (dq: Dequeue[R]): Option[R] / {} - check
[R] (dq: Dequeue[R]): Dequeue[R] / {} - pushFront
[R] (dq: Dequeue[R], el: R): Dequeue[R] / {} - popFront
[R] (dq: Dequeue[R]): Option[Tuple2[R, Dequeue[R]]] / {} - pushBack
[R] (dq: Dequeue[R], el: R): Dequeue[R] / {} - popBack
[R] (dq: Dequeue[R]): Option[Tuple2[R, Dequeue[R]]] / {} - show
[A] (d: Dequeue[A]) { showA: (A) => String }: String / {} - show
(l: Dequeue[Int]): String / {} - show
(l: Dequeue[Double]): String / {} - show
(l: Dequeue[Bool]): String / {} - show
(l: Dequeue[String]): String / {} - println
(l: Dequeue[Int]): Unit / {} - println
(l: Dequeue[Double]): Unit / {} - println
(l: Dequeue[Bool]): Unit / {} - println
(l: Dequeue[String]): Unit / {}
Example usage: examples/stdlib/dequeue
An implementation of a functional dequeue, using Okasaki's bankers dequeue implementation. Translation from the Haskell implementation: https://hackage.haskell.org/package/dequeue-0.1.12/docs/src/Data-Dequeue.html#Dequeue