You need to rename files throughout an entire directory tree, for example, you want to change extension of every file with a particular extension to something else.
I wrote this solution to use for-each because the rename operation is a side effect. You could also use fold-files, which isn't quite as good a fit because it accumulates a result, but the definition is a bit more concise. It also doesn't explicitly build up a list of files to modify first, which can amount to a lot of memory on a big directory tree.