RightRightLeftPathCount
The number of nodes from which taking the right, then the right, then the left child stays inside the tree.
✓ checked against that system · ! checked, with disagreements (hover a chip)FindStat
St000122via BinaryTree✓RightRightLeftPathCount(tree)The number of nodes from which taking the right, then the right, then the left child stays inside the tree.Typed signatures
| Type | Package | Applies |
|---|---|---|
(binary_tree) -> number | combinatorics | always |
Details
- Defined over
BinaryTreeas an expression in_x, evaluated by compute-engine — the definition IS the implementation. - Takes a
BinaryTreeand nothing else — it reads values against their positions, or walks the orbits, so it needs the bijection. Applying it to a bare list is a type error, not a wrong answer. - A contiguous pattern of nodes along one path, the subtrees off it anything.
Definition
Epsil, as the implementation runs it.
on BinaryTree, over _x
Apply(
Function(0 if t in Integers else (0 if t[2] in Integers else 0 if t[2][2] in
Integers else 0 if t[2][2][1] in Integers else 1) +
self(self, t[1]) + self(self, t[2]), self, t),
Function(0 if t in Integers else (0 if t[2] in Integers else 0 if t[2][2] in
Integers else 0 if t[2][2][1] in Integers else 1) +
self(self, t[1]) + self(self, t[2]), self, t),
_x,
)Examples
Properties #
About
| Examples | 4 |
|---|---|
| Crosswalk | FindStat |