by mafribe · 10y ago · 0 comments
But simple loops are not as expressive as full loops (where you can modify the loop variable). As a simple example, try to phrase the Euclid's algorithm for computing the GCD using "for(int i = 0; i < n; i++) { ... }" where "i" is not modified in the loop body.
I'm really just advocating a rule of least power. Don't go into full general recursion just because you can.