`for/fold` + specialization for a few arities.