I have a sequence:
[a b c ...]
And the function (f x y). I want to get the following:
(f x y)
(f c (f b (f a 1)))
Etc .. How to do this?
Reduce, with a little adaptation:
(reduce #(f %2 %1) 1 [a b c])
(reduce (fn [acc x] (f x acc)) 1 [a b c d])