Documentation states
A negative level
-n
consists of all parts of expr with depthn
.
However, it is not clear what do level specifications {m, n}
with negative m
or n
mean.
I made several guesses, like
{-m, n}
means “in all subexpressions of depthm
, all subexpressions on levelsn
or before”
that were disproven by counterexamples (e.g., Level[h[1, h[2, h[3]]], {-2, 2}]
does not incude 3
) but I don't think I should have been guessing in the first place. Still, documentation does not provide an exhaustive set of examples on this.
The question is,
How should levelspecs {m, -n}
, {-m, n}
, {-m, -n}
be interpreted, in English?
P.S. I included tag “list-manipulation” only because it was the one used in this question. No existing tag actually looks appropriate.