Activity 4.41.1.
Which loop would be best for this problem?
-
while
-
A while loop is the best choice when you donβt know the number of times you need to loop.
-
for
-
You could use a for loop, but there is a more concise option since you are not changing any values of wordList.
-
for-each
-
Correct! A for-each loop is the most concise way to access every string in wordList to keep track of numLetters



