ZVON > References > Haskell reference
| Indexes | Syntax | >> Prelude << | Ratio | Complex | Numeric | Ix | Array | List | Maybe | Char | Monad | IO | Directory | System | Time | Locale | CPUTime | Random

Module: Prelude
Function: enumFromTo
Type: Enum a => a -> a -> [a]
Class: Enum
Description: returns an array of members of an enumeration starting with the first argument and finishing with the second one, it is equvalent to syntax.
Related: enumFrom, enumFromThen, enumFromThenTo, fromEnum, pred, succ, toEnum

Example 1

Input: enumFromTo 'c' 'g'

Output: "cdefg"

Example 2

Input: enumFromTo 12 17

Output: [12,13,14,15,16,17]

Example 3
Program source: 
data XXX = AA|BB|CC|DD|EE|FF|GG deriving (Enum, Show)

Input: enumFromTo BB FF

Output: [BB,CC,DD,EE,FF]