Skip to content

Commit 187b317

Browse files
committed
Improve ch03-05-control-flow collection looping wording
This makes it clearer, that you COULD use a `while` loop to loop a collection, but a `for` loop is the preferred way
1 parent 3dca2fc commit 187b317

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ch03-05-control-flow.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ evaluates to `true`, the code runs; otherwise, it exits the loop.
297297

298298
#### Looping Through a Collection with `for`
299299

300-
You can choose to use the `while` construct to loop over the elements of a
300+
You could choose to use the `while` construct to loop over the elements of a
301301
collection, such as an array. For example, the loop in Listing 3-4 prints each
302302
element in the array `a`.
303303

0 commit comments

Comments
 (0)