I originally wrote `while` loops everywhere to avoid the overhead of a closure in a normal `foreach` (or even worse, `map` and friends).  But, I've since discovered that `Range.foreach` is *almost* as good -- the scala compiler can eliminate the closure.  I find my while loops are extremely error prone, I often forget to increment the idx and then have an infinite loop in my tests, so for now in general I'm using `Range.foreach`.

`foreach` on anything other than `Range` has pretty serious overhead, though