uulib-0.9.5: Haskell Utrecht Tools Library

UU.DData.Seq

Contents

Description

 

Synopsis

Type

data Seq a Source

Sequences of values a.

Operators

(<>) :: Seq a -> Seq a -> Seq aSource

O(1). Append two sequences, see append.

Construction

empty :: Seq aSource

O(1). Create an empty sequence.

single :: a -> Seq aSource

O(1). Create a sequence of one element.

cons :: a -> Seq a -> Seq aSource

O(1). Put a value in front of a sequence.

append :: Seq a -> Seq a -> Seq aSource

O(1). Append two sequences.

Conversion

toList :: Seq a -> [a]Source

O(n). Convert a sequence to a list.

fromList :: [a] -> Seq aSource

O(n). Create a sequence from a list.