Append a list to this DList O(1)
Prepend a single element to this DList O(1)
append a single element to this DList O(1)
Prepend the contents of this dlist to the given tail.
Get the first element of the list, if any.
Get the first element of the list, if any. O(n) where n is the number of append operations in this DList
Tests whether list is empty.
Tests whether list is empty. O(n) where n is the number of append operations in this DList which is a bit weirdly expensive
Get the tail of the list, if any.
Get the tail of the list, if any. O(n) where n is the number of append operations in this DList
O(n)
Destructure the DList into a head and a tail, and pass both to a function O(n) where n is the number of append operations in this DList
A "difference list" - A List like structure with O(1) appends. Based on
Data.DList
, a Haskell library by Don Stewart.