Actually, for loops in languages like Ruby and OCaml are just syntactic sugar for map.
Also, why would you prefer an imperative construct over different kinds of folds?
Also, why would you prefer an imperative construct over different kinds of folds?
Why are maps and folds so prevalent in functional programming? Because immutability and imperativeness render the concept of a for loop to be non-existent.
Try to use a for loop with all const variables and no IO... your for loop will not be able to do any meaningful change to the state of your program.