[Haskell-cafe] lexicographic order

Niklas Broberg niklas.broberg at gmail.com
Sun Mar 30 17:10:25 EDT 2008


>  Although I have tried to make sense what lexicographic order means I haven't
>  figured out. Maybe an example with a simple application of this would be
>  helpful. To be honest I can't understand what the symbol <= really means.

<= means "less than or equal to".

Normally, lexicograpic order is the order in which words would appear
in a lexicon. This can be generalized to other data types than strings
by the kind of comparison done here, by specifying an ordering of the
constructors (in this case Leaf < Branch).

Cheers,

/Niklas


More information about the Haskell-Cafe mailing list