Open
Description
If you have loop
/recur
consider looking at the whole sequence api
- If you want to apply a transformation to each element reach for
map
/mapv
- If you’re looking to remove items, look at things like
distinct
,set
,filter
,remove
,keep
… - If you want to apply a side effect for each element reach for
run!
/doseq
/doall
… - If you want to produce a single compound value from many look for specialised functions first, then at
reduce
- If you want to produce a sequence of values that depend on the previous value look at
iterate
… - If you need to manipulate something stateful into being a sequence-like thing look at
lazy-seq
or a transducers.
There are many many more — for example: using transducers