+ 2

how

how the answer is 7

23rd Jul 2016, 6:02 AM
Raghul Jothiraman
Raghul Jothiraman - avatar
3 ответов
+ 1
After the reforms the number 4 is in the list, so you need to display the fourth element of the list (after zero, first and second).
23rd Jul 2016, 8:36 AM
Alexander T.
Alexander T. - avatar
0
if the answer is 7, then they should have been asked question like this 'if nums[0]=4'
23rd Jul 2016, 6:04 AM
Raghul Jothiraman
Raghul Jothiraman - avatar
0
simple reasoning: it does NOT matter how new symbols are added into the List, either by APPEND or INSERT, as long as the final function LEN calculates the length of the entire List (e.g. string). There are 5 initial elements, and 2 more were added later... so, we get 5+2 == 7 as the correct answer.
28th Jul 2016, 6:19 AM
Eugene E
Eugene E - avatar