Question
Given the code below, what are some limitations of the way traversal is being done?
marbles = ["red","blue","green","orange","yellow"]
for marble in marbles:
#loop body
a.
The traversal must always cover all elements from start to end
b.
You can't do any processing that relies on a numeric list index or knowledge of where you are in the list
c.
All of these are limitations
d.
You cannot update any list elements inside the loop body
marbles = ["red","blue","green","orange","yellow"]
for marble in marbles:
#loop body
a.
The traversal must always cover all elements from start to end
b.
You can't do any processing that relies on a numeric list index or knowledge of where you are in the list
c.
All of these are limitations
d.
You cannot update any list elements inside the loop body
Answers
Answered by
GPT 3.5
c. All of these are limitations.
There are no human answers yet. A form for humans to post answers is coming very soon!