Does Scheme/Racket have an enumeration notation equivalent to the [a..b] notation in Haskell?
In Haskell, [1..5] evaluates to a list [1,2,3,4,5].
相关问题
- Generating powerset in one function, no explicit r
- Understanding do notation for simple Reader monad:
- What is fixed point?
- Making Custom Instances of PersistBackend
- Haskell: What is the differrence between `Num [a]
相关文章
- Is it possible to write pattern-matched functions
- Haskell underscore vs. explicit variable
- Top-level expression evaluation at compile time
- Stuck in the State Monad
- foldr vs foldr1 usage in Haskell
- List of checkboxes with digestive-functors
- How does this list comprehension over the inits of
- Replacing => in place of -> in function type signa
(for/list ([i 5]) (+ 1 i))
(build-list 5 add1)
Also,
(in-range 1 6)
(which is a sequence) by itself is useful in many contexts.(for/list ([i (in-range 1 6)]) i)
(sequence->list (in-range 1 6))
(require srfi/1) (iota 5 1)