[Python-Dev] Three argument slices.
04 Nov 2000 16:47:31 +0000
email@example.com (Finn Bock) writes:
> While updating the difference page in the Jython documentation, I
> came across this:
> - JPython sequences support three argument slices. i.e.
> range(3)[::-1] == [2,1,0].
> CPython should be fixed.
> Is this actually true? Should (and will cpython) change in this
Well, there's a patch I wrote on sf to add this to CPython, but it was
too late for 2.0 and it got postponed.
Does J[P]ython allow
l = range(10)
l[::3] = range(4)
? That's one of the odder bits of the behaviour of my patch.
58. Fools ignore complexity. Pragmatists suffer it. Some can avoid
it. Geniuses remove it.
-- Alan Perlis, http://www.cs.yale.edu/homes/perlis-alan/quotes.html