Chapter Review Questions
Describe in general when a
foreach
loop is going to be easier to use than awhile
loop.Even if you want to process every element of a sequence, what would keep you from using a
foreach
loop?
Describe in general when a foreach
loop is going to be easier to use
than a while
loop.
Even if you want to process every element of a sequence, what would keep
you from using a foreach
loop?