What is the output of the following code snippet?
aLst = [1,2,3,4,5,6,7,8,9]
print(aLst[::-3])]
Answers
Answered by
2
Answer:
[9,6,3]
Explanation:
here '-' indicates the reverse order
and 3 indicates the increment
1 2 3 4 5 6 7 8 9
| | |
Here it prints from reverse with increment of 3.
-1 will printed
then -1+ (-3)=-4
then -4+(-3)=-7
so these position values are printed.
Answered by
1
Answer:
9,6,3
Explanation:
hope u help this, all kind
Similar questions