I just changed one of my scripts that, in principle, looked like this: for i in `find . -type d`do # do some processing on the found directorydone The new format I use is: find . -type d | while read ido # do some processing on the found directorydone While both versions will work in general, the second variant is better for the following reasons: It's faster.