i solved the problem but i wont understand the part how the all elements stored in the beginning of list changed for displaying those in reverse order from begin to end.
please explain if you know!
thanks in advance!
How in the world it occurs?
Under discussion
Comments (3)
- Popular
- New
- Old
You must be signed in to leave a comment
Sanjeevkumar
9 July 2020, 17:47
thank you all i figured it out !
+1
Mike McKenna
10 June 2020, 20:44
Hi,
wish u had included @ least some code . that way i would have better idea how u solved task . as u i solved task as a level 7 . i looked @ tasks that were similar ,level 6 lesson 11 was helpful . without u r code i found that all i was doing is writing my code not helping u understand .
only trying to help
+1
Thomas
10 June 2020, 07:37
if you always add at the beginning, then it looks similar to, first element
1
adding the second element, the first getting shifted to the right
2 1
now adding the third, 2 and 1 gettinge shifted again to the right so that there is room for 3
3 2 1
if you now loop through the list it seems it's in reverse order.
0