79512959

Date: 2025-03-16 17:34:19
Score: 2
Natty:
Report link

That is because -1 in slice means the last element.

Although list(range(4,-1,-1)) = [4 , 3, 2, 1,0],

[4:-1:-1] doesnt equal to it.

[4:-1:-1] = [4:-1+len:-1] != [4::-1]

[4::-1] is what you want.

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: east_laugh