MCPcopy Index your code
hub / github.com/trekhleb/javascript-algorithms / getRightChildIndex

Method getRightChildIndex

src/data-structures/heap/Heap.js:33–35  ·  view source on GitHub ↗

* @param {number} parentIndex * @return {number}

(parentIndex)

Source from the content-addressed store, hash-verified

31 * @return {number}
32 */
33 getRightChildIndex(parentIndex) {
34 return (2 * parentIndex) + 2;
35 }
36
37 /**
38 * @param {number} childIndex

Callers 3

hasRightChildMethod · 0.95
rightChildMethod · 0.95
heapifyDownMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected