data-structure-typed 1.18.0 → 1.18.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (290) hide show
  1. package/README.md +193 -66
  2. package/backup/recursive-type/src/assets/complexities-diff.jpg +0 -0
  3. package/backup/recursive-type/src/assets/data-structure-complexities.jpg +0 -0
  4. package/backup/recursive-type/src/assets/logo.png +0 -0
  5. package/backup/recursive-type/src/assets/overview-diagram-of-data-structures.png +0 -0
  6. package/backup/recursive-type/src/data-structures/binary-tree/aa-tree.ts +3 -0
  7. package/backup/recursive-type/src/data-structures/binary-tree/avl-tree.ts +288 -0
  8. package/backup/recursive-type/src/data-structures/binary-tree/b-tree.ts +3 -0
  9. package/backup/recursive-type/src/data-structures/binary-tree/binary-indexed-tree.ts +78 -0
  10. package/backup/recursive-type/src/data-structures/binary-tree/binary-tree.ts +1502 -0
  11. package/backup/recursive-type/src/data-structures/binary-tree/bst.ts +503 -0
  12. package/backup/recursive-type/src/data-structures/binary-tree/diagrams/avl-tree-inserting.gif +0 -0
  13. package/backup/recursive-type/src/data-structures/binary-tree/diagrams/bst-rotation.gif +0 -0
  14. package/backup/recursive-type/src/data-structures/binary-tree/diagrams/segment-tree.png +0 -0
  15. package/backup/recursive-type/src/data-structures/binary-tree/index.ts +11 -0
  16. package/backup/recursive-type/src/data-structures/binary-tree/rb-tree.ts +110 -0
  17. package/backup/recursive-type/src/data-structures/binary-tree/segment-tree.ts +243 -0
  18. package/backup/recursive-type/src/data-structures/binary-tree/splay-tree.ts +3 -0
  19. package/backup/recursive-type/src/data-structures/binary-tree/tree-multiset.ts +55 -0
  20. package/backup/recursive-type/src/data-structures/binary-tree/two-three-tree.ts +3 -0
  21. package/backup/recursive-type/src/data-structures/diagrams/README.md +5 -0
  22. package/backup/recursive-type/src/data-structures/graph/abstract-graph.ts +985 -0
  23. package/backup/recursive-type/src/data-structures/graph/diagrams/adjacency-list-pros-cons.jpg +0 -0
  24. package/backup/recursive-type/src/data-structures/graph/diagrams/adjacency-list.jpg +0 -0
  25. package/backup/recursive-type/src/data-structures/graph/diagrams/adjacency-matrix-pros-cons.jpg +0 -0
  26. package/backup/recursive-type/src/data-structures/graph/diagrams/adjacency-matrix.jpg +0 -0
  27. package/backup/recursive-type/src/data-structures/graph/diagrams/dfs-can-do.jpg +0 -0
  28. package/backup/recursive-type/src/data-structures/graph/diagrams/edge-list-pros-cons.jpg +0 -0
  29. package/backup/recursive-type/src/data-structures/graph/diagrams/edge-list.jpg +0 -0
  30. package/backup/recursive-type/src/data-structures/graph/diagrams/max-flow.jpg +0 -0
  31. package/backup/recursive-type/src/data-structures/graph/diagrams/mst.jpg +0 -0
  32. package/backup/recursive-type/src/data-structures/graph/diagrams/tarjan-articulation-point-bridge.png +0 -0
  33. package/backup/recursive-type/src/data-structures/graph/diagrams/tarjan-complicate-simple.png +0 -0
  34. package/backup/recursive-type/src/data-structures/graph/diagrams/tarjan-strongly-connected-component.png +0 -0
  35. package/backup/recursive-type/src/data-structures/graph/diagrams/tarjan.mp4 +0 -0
  36. package/backup/recursive-type/src/data-structures/graph/diagrams/tarjan.webp +0 -0
  37. package/backup/recursive-type/src/data-structures/graph/directed-graph.ts +478 -0
  38. package/backup/recursive-type/src/data-structures/graph/index.ts +3 -0
  39. package/backup/recursive-type/src/data-structures/graph/undirected-graph.ts +293 -0
  40. package/backup/recursive-type/src/data-structures/hash/coordinate-map.ts +67 -0
  41. package/backup/recursive-type/src/data-structures/hash/coordinate-set.ts +56 -0
  42. package/backup/recursive-type/src/data-structures/hash/hash-table.ts +3 -0
  43. package/backup/recursive-type/src/data-structures/hash/index.ts +6 -0
  44. package/backup/recursive-type/src/data-structures/hash/pair.ts +3 -0
  45. package/backup/recursive-type/src/data-structures/hash/tree-map.ts +3 -0
  46. package/backup/recursive-type/src/data-structures/hash/tree-set.ts +3 -0
  47. package/backup/recursive-type/src/data-structures/heap/heap.ts +176 -0
  48. package/backup/recursive-type/src/data-structures/heap/index.ts +3 -0
  49. package/backup/recursive-type/src/data-structures/heap/max-heap.ts +31 -0
  50. package/backup/recursive-type/src/data-structures/heap/min-heap.ts +34 -0
  51. package/backup/recursive-type/src/data-structures/index.ts +15 -0
  52. package/backup/recursive-type/src/data-structures/interfaces/abstract-graph.ts +42 -0
  53. package/backup/recursive-type/src/data-structures/interfaces/avl-tree.ts +1 -0
  54. package/backup/recursive-type/src/data-structures/interfaces/binary-tree.ts +56 -0
  55. package/backup/recursive-type/src/data-structures/interfaces/bst.ts +1 -0
  56. package/backup/recursive-type/src/data-structures/interfaces/directed-graph.ts +15 -0
  57. package/backup/recursive-type/src/data-structures/interfaces/doubly-linked-list.ts +1 -0
  58. package/backup/recursive-type/src/data-structures/interfaces/heap.ts +1 -0
  59. package/backup/recursive-type/src/data-structures/interfaces/index.ts +13 -0
  60. package/backup/recursive-type/src/data-structures/interfaces/navigator.ts +1 -0
  61. package/backup/recursive-type/src/data-structures/interfaces/priority-queue.ts +1 -0
  62. package/backup/recursive-type/src/data-structures/interfaces/segment-tree.ts +1 -0
  63. package/backup/recursive-type/src/data-structures/interfaces/singly-linked-list.ts +1 -0
  64. package/backup/recursive-type/src/data-structures/interfaces/tree-multiset.ts +1 -0
  65. package/backup/recursive-type/src/data-structures/interfaces/undirected-graph.ts +3 -0
  66. package/backup/recursive-type/src/data-structures/linked-list/doubly-linked-list.ts +573 -0
  67. package/backup/recursive-type/src/data-structures/linked-list/index.ts +3 -0
  68. package/backup/recursive-type/src/data-structures/linked-list/singly-linked-list.ts +490 -0
  69. package/backup/recursive-type/src/data-structures/linked-list/skip-linked-list.ts +3 -0
  70. package/backup/recursive-type/src/data-structures/matrix/index.ts +4 -0
  71. package/backup/recursive-type/src/data-structures/matrix/matrix.ts +27 -0
  72. package/backup/recursive-type/src/data-structures/matrix/matrix2d.ts +208 -0
  73. package/backup/recursive-type/src/data-structures/matrix/navigator.ts +122 -0
  74. package/backup/recursive-type/src/data-structures/matrix/vector2d.ts +316 -0
  75. package/backup/recursive-type/src/data-structures/priority-queue/index.ts +3 -0
  76. package/backup/recursive-type/src/data-structures/priority-queue/max-priority-queue.ts +49 -0
  77. package/backup/recursive-type/src/data-structures/priority-queue/min-priority-queue.ts +50 -0
  78. package/backup/recursive-type/src/data-structures/priority-queue/priority-queue.ts +354 -0
  79. package/backup/recursive-type/src/data-structures/queue/deque.ts +251 -0
  80. package/backup/recursive-type/src/data-structures/queue/index.ts +2 -0
  81. package/backup/recursive-type/src/data-structures/queue/queue.ts +120 -0
  82. package/backup/recursive-type/src/data-structures/stack/index.ts +1 -0
  83. package/backup/recursive-type/src/data-structures/stack/stack.ts +98 -0
  84. package/backup/recursive-type/src/data-structures/tree/index.ts +1 -0
  85. package/backup/recursive-type/src/data-structures/tree/tree.ts +80 -0
  86. package/backup/recursive-type/src/data-structures/trie/index.ts +1 -0
  87. package/backup/recursive-type/src/data-structures/trie/trie.ts +227 -0
  88. package/backup/recursive-type/src/data-structures/types/abstract-graph.ts +5 -0
  89. package/backup/recursive-type/src/data-structures/types/avl-tree.ts +8 -0
  90. package/backup/recursive-type/src/data-structures/types/binary-tree.ts +10 -0
  91. package/backup/recursive-type/src/data-structures/types/bst.ts +6 -0
  92. package/backup/recursive-type/src/data-structures/types/directed-graph.ts +8 -0
  93. package/backup/recursive-type/src/data-structures/types/doubly-linked-list.ts +1 -0
  94. package/backup/recursive-type/src/data-structures/types/heap.ts +5 -0
  95. package/backup/recursive-type/src/data-structures/types/index.ts +12 -0
  96. package/backup/recursive-type/src/data-structures/types/navigator.ts +13 -0
  97. package/backup/recursive-type/src/data-structures/types/priority-queue.ts +9 -0
  98. package/backup/recursive-type/src/data-structures/types/segment-tree.ts +1 -0
  99. package/backup/recursive-type/src/data-structures/types/singly-linked-list.ts +1 -0
  100. package/backup/recursive-type/src/data-structures/types/tree-multiset.ts +1 -0
  101. package/backup/recursive-type/src/index.ts +1 -0
  102. package/backup/recursive-type/src/utils/index.ts +2 -0
  103. package/backup/recursive-type/src/utils/types/index.ts +1 -0
  104. package/backup/recursive-type/src/utils/types/utils.ts +6 -0
  105. package/backup/recursive-type/src/utils/utils.ts +78 -0
  106. package/dist/data-structures/binary-tree/abstract-binary-tree.d.ts +333 -0
  107. package/dist/data-structures/binary-tree/abstract-binary-tree.js +1455 -0
  108. package/dist/data-structures/binary-tree/avl-tree.d.ts +20 -25
  109. package/dist/data-structures/binary-tree/avl-tree.js +10 -18
  110. package/dist/data-structures/binary-tree/binary-tree.d.ts +18 -345
  111. package/dist/data-structures/binary-tree/binary-tree.js +39 -1444
  112. package/dist/data-structures/binary-tree/bst.d.ts +24 -31
  113. package/dist/data-structures/binary-tree/bst.js +46 -53
  114. package/dist/data-structures/binary-tree/index.d.ts +1 -0
  115. package/dist/data-structures/binary-tree/index.js +1 -0
  116. package/dist/data-structures/binary-tree/rb-tree.d.ts +1 -2
  117. package/dist/data-structures/binary-tree/rb-tree.js +64 -5
  118. package/dist/data-structures/binary-tree/tree-multiset.d.ts +11 -25
  119. package/dist/data-structures/binary-tree/tree-multiset.js +29 -31
  120. package/dist/data-structures/graph/abstract-graph.d.ts +56 -58
  121. package/dist/data-structures/graph/abstract-graph.js +84 -68
  122. package/dist/data-structures/graph/directed-graph.d.ts +124 -95
  123. package/dist/data-structures/graph/directed-graph.js +156 -108
  124. package/dist/data-structures/graph/undirected-graph.d.ts +83 -58
  125. package/dist/data-structures/graph/undirected-graph.js +98 -71
  126. package/dist/data-structures/hash/coordinate-set.d.ts +1 -1
  127. package/dist/data-structures/index.d.ts +1 -0
  128. package/dist/data-structures/index.js +1 -0
  129. package/dist/data-structures/interfaces/abstract-graph.d.ts +22 -0
  130. package/dist/data-structures/interfaces/abstract-graph.js +2 -0
  131. package/dist/data-structures/interfaces/avl-tree.d.ts +1 -0
  132. package/dist/data-structures/interfaces/avl-tree.js +2 -0
  133. package/dist/data-structures/interfaces/binary-tree.d.ts +26 -0
  134. package/dist/data-structures/interfaces/binary-tree.js +2 -0
  135. package/dist/data-structures/interfaces/bst.d.ts +1 -0
  136. package/dist/data-structures/interfaces/bst.js +2 -0
  137. package/dist/data-structures/interfaces/directed-graph.d.ts +9 -0
  138. package/dist/data-structures/interfaces/directed-graph.js +2 -0
  139. package/dist/data-structures/interfaces/doubly-linked-list.d.ts +1 -0
  140. package/dist/data-structures/interfaces/doubly-linked-list.js +2 -0
  141. package/dist/data-structures/interfaces/heap.d.ts +1 -0
  142. package/dist/data-structures/interfaces/heap.js +2 -0
  143. package/dist/data-structures/interfaces/index.d.ts +13 -0
  144. package/dist/data-structures/interfaces/index.js +29 -0
  145. package/dist/data-structures/interfaces/navigator.d.ts +1 -0
  146. package/dist/data-structures/interfaces/navigator.js +2 -0
  147. package/dist/data-structures/interfaces/priority-queue.d.ts +1 -0
  148. package/dist/data-structures/interfaces/priority-queue.js +2 -0
  149. package/dist/data-structures/interfaces/segment-tree.d.ts +1 -0
  150. package/dist/data-structures/interfaces/segment-tree.js +2 -0
  151. package/dist/data-structures/interfaces/singly-linked-list.d.ts +1 -0
  152. package/dist/data-structures/interfaces/singly-linked-list.js +2 -0
  153. package/dist/data-structures/interfaces/tree-multiset.d.ts +1 -0
  154. package/dist/data-structures/interfaces/tree-multiset.js +2 -0
  155. package/dist/data-structures/interfaces/undirected-graph.d.ts +2 -0
  156. package/dist/data-structures/interfaces/undirected-graph.js +2 -0
  157. package/dist/data-structures/linked-list/doubly-linked-list.d.ts +1 -1
  158. package/dist/data-structures/linked-list/singly-linked-list.d.ts +1 -1
  159. package/dist/data-structures/priority-queue/priority-queue.d.ts +1 -1
  160. package/dist/data-structures/priority-queue/priority-queue.js +4 -4
  161. package/dist/data-structures/queue/deque.d.ts +5 -5
  162. package/dist/data-structures/queue/deque.js +6 -6
  163. package/dist/data-structures/queue/queue.d.ts +1 -1
  164. package/dist/data-structures/stack/stack.d.ts +1 -1
  165. package/dist/data-structures/types/abstract-binary-tree.d.ts +32 -0
  166. package/dist/data-structures/types/abstract-binary-tree.js +21 -0
  167. package/dist/data-structures/types/abstract-graph.d.ts +1 -20
  168. package/dist/data-structures/types/avl-tree.d.ts +3 -4
  169. package/dist/data-structures/types/binary-tree.d.ts +3 -10
  170. package/dist/data-structures/types/bst.d.ts +10 -4
  171. package/dist/data-structures/types/bst.js +7 -0
  172. package/dist/data-structures/types/directed-graph.d.ts +5 -9
  173. package/dist/data-structures/types/directed-graph.js +7 -0
  174. package/dist/data-structures/types/heap.d.ts +2 -2
  175. package/dist/data-structures/types/helpers.d.ts +8 -0
  176. package/dist/data-structures/types/helpers.js +2 -0
  177. package/dist/data-structures/types/index.d.ts +3 -1
  178. package/dist/data-structures/types/index.js +3 -1
  179. package/dist/data-structures/types/navigator.d.ts +2 -2
  180. package/dist/data-structures/types/priority-queue.d.ts +2 -2
  181. package/dist/data-structures/types/rb-tree.d.ts +6 -0
  182. package/dist/data-structures/types/rb-tree.js +8 -0
  183. package/dist/data-structures/types/tree-multiset.d.ts +5 -4
  184. package/docs/assets/search.js +1 -1
  185. package/docs/classes/AVLTree.html +310 -309
  186. package/docs/classes/AVLTreeNode.html +122 -68
  187. package/docs/classes/AaTree.html +30 -17
  188. package/docs/classes/AbstractBinaryTree.html +2023 -0
  189. package/docs/classes/AbstractBinaryTreeNode.html +491 -0
  190. package/docs/classes/AbstractEdge.html +84 -39
  191. package/docs/classes/AbstractGraph.html +235 -119
  192. package/docs/classes/AbstractVertex.html +87 -35
  193. package/docs/classes/ArrayDeque.html +43 -30
  194. package/docs/classes/BST.html +297 -285
  195. package/docs/classes/BSTNode.html +123 -62
  196. package/docs/classes/BTree.html +30 -17
  197. package/docs/classes/BinaryIndexedTree.html +38 -25
  198. package/docs/classes/BinaryTree.html +596 -589
  199. package/docs/classes/BinaryTreeNode.html +181 -161
  200. package/docs/classes/Character.html +33 -20
  201. package/docs/classes/CoordinateMap.html +38 -25
  202. package/docs/classes/CoordinateSet.html +39 -26
  203. package/docs/classes/Deque.html +63 -50
  204. package/docs/classes/DirectedEdge.html +90 -46
  205. package/docs/classes/DirectedGraph.html +374 -212
  206. package/docs/classes/DirectedVertex.html +79 -41
  207. package/docs/classes/DoublyLinkedList.html +68 -55
  208. package/docs/classes/DoublyLinkedListNode.html +40 -27
  209. package/docs/classes/HashTable.html +30 -17
  210. package/docs/classes/Heap.html +45 -32
  211. package/docs/classes/HeapItem.html +37 -24
  212. package/docs/classes/Matrix2D.html +45 -32
  213. package/docs/classes/MatrixNTI2D.html +33 -20
  214. package/docs/classes/MaxHeap.html +45 -32
  215. package/docs/classes/MaxPriorityQueue.html +83 -65
  216. package/docs/classes/MinHeap.html +45 -32
  217. package/docs/classes/MinPriorityQueue.html +83 -65
  218. package/docs/classes/Navigator.html +40 -27
  219. package/docs/classes/ObjectDeque.html +78 -55
  220. package/docs/classes/Pair.html +30 -17
  221. package/docs/classes/PriorityQueue.html +78 -60
  222. package/docs/classes/Queue.html +45 -32
  223. package/docs/classes/SegmentTree.html +46 -33
  224. package/docs/classes/SegmentTreeNode.html +49 -36
  225. package/docs/classes/SinglyLinkedList.html +65 -52
  226. package/docs/classes/SinglyLinkedListNode.html +37 -24
  227. package/docs/classes/SkipLinkedList.html +30 -17
  228. package/docs/classes/SplayTree.html +30 -17
  229. package/docs/classes/Stack.html +43 -30
  230. package/docs/classes/TreeMap.html +30 -17
  231. package/docs/classes/TreeMultiSet.html +330 -316
  232. package/docs/classes/TreeMultiSetNode.html +450 -0
  233. package/docs/classes/TreeNode.html +45 -32
  234. package/docs/classes/TreeSet.html +30 -17
  235. package/docs/classes/Trie.html +42 -29
  236. package/docs/classes/TrieNode.html +40 -27
  237. package/docs/classes/TwoThreeTree.html +30 -17
  238. package/docs/classes/UndirectedEdge.html +86 -56
  239. package/docs/classes/UndirectedGraph.html +286 -165
  240. package/docs/classes/UndirectedVertex.html +79 -41
  241. package/docs/classes/Vector2D.html +57 -44
  242. package/docs/enums/CP.html +36 -23
  243. package/docs/enums/FamilyPosition.html +48 -35
  244. package/docs/enums/LoopType.html +42 -29
  245. package/docs/{interfaces/PriorityQueueOptions.html → enums/RBColor.html} +52 -55
  246. package/docs/{interfaces/AVLTreeDeleted.html → enums/TopologicalProperty.html} +59 -48
  247. package/docs/index.html +211 -73
  248. package/docs/interfaces/{NavigatorParams.html → IBinaryTree.html} +56 -67
  249. package/docs/interfaces/IBinaryTreeNode.html +396 -0
  250. package/docs/interfaces/IDirectedGraph.html +36 -23
  251. package/docs/interfaces/IGraph.html +134 -93
  252. package/docs/interfaces/{HeapOptions.html → IUNDirectedGraph.html} +38 -57
  253. package/docs/modules.html +57 -31
  254. package/docs/types/{ToThunkFn.html → AVLTreeOptions.html} +35 -27
  255. package/docs/types/AbstractBinaryTreeOptions.html +150 -0
  256. package/docs/types/AbstractRecursiveBinaryTreeNode.html +146 -0
  257. package/docs/types/{ResultsByProperty.html → AbstractResultByProperty.html} +35 -22
  258. package/docs/types/{TreeMultiSetDeletedResult.html → AbstractResultsByProperty.html} +35 -29
  259. package/docs/types/BSTComparator.html +30 -17
  260. package/docs/types/{TrlAsyncFn.html → BSTOptions.html} +36 -31
  261. package/docs/types/BinaryTreeDeletedResult.html +153 -0
  262. package/docs/types/BinaryTreeNodeId.html +30 -17
  263. package/docs/types/BinaryTreeNodePropertyName.html +30 -17
  264. package/docs/types/{BinaryTreeDeleted.html → BinaryTreeOptions.html} +35 -31
  265. package/docs/types/DFSOrderPattern.html +30 -17
  266. package/docs/types/DijkstraResult.html +30 -17
  267. package/docs/types/Direction.html +30 -17
  268. package/docs/types/{SpecifyOptional.html → EdgeId.html} +34 -28
  269. package/docs/types/{TrlFn.html → HeapOptions.html} +45 -24
  270. package/docs/types/IdObject.html +151 -0
  271. package/docs/types/{BSTDeletedResult.html → KeyValObject.html} +36 -30
  272. package/docs/types/NavigatorParams.html +175 -0
  273. package/docs/types/NodeOrPropertyName.html +30 -17
  274. package/docs/types/PriorityQueueComparator.html +30 -17
  275. package/docs/types/PriorityQueueDFSOrderPattern.html +30 -17
  276. package/docs/types/PriorityQueueOptions.html +155 -0
  277. package/docs/types/{Thunk.html → RBTreeOptions.html} +35 -27
  278. package/docs/types/RecursiveAVLTreeNode.html +146 -0
  279. package/docs/types/RecursiveBSTNode.html +146 -0
  280. package/docs/types/RecursiveBinaryTreeNode.html +146 -0
  281. package/docs/types/RecursiveTreeMultiSetNode.html +146 -0
  282. package/docs/types/SegmentTreeNodeVal.html +30 -17
  283. package/docs/types/TopologicalStatus.html +30 -17
  284. package/docs/types/TreeMultiSetOptions.html +146 -0
  285. package/docs/types/Turning.html +30 -17
  286. package/docs/types/VertexId.html +30 -17
  287. package/notes/note.md +8 -1
  288. package/package.json +10 -2
  289. package/docs/classes/RBTree.html +0 -153
  290. package/docs/types/ResultByProperty.html +0 -133
@@ -14,20 +14,28 @@
14
14
  <ul class="tsd-breadcrumb">
15
15
  <li><a href="../modules.html">data-structure-typed</a></li>
16
16
  <li><a href="TreeMultiSet.html">TreeMultiSet</a></li></ul>
17
- <h1>Class TreeMultiSet&lt;T&gt;</h1></div>
17
+ <h1>Class TreeMultiSet&lt;N&gt;</h1></div>
18
+ <section class="tsd-panel tsd-comment">
19
+ <div class="tsd-comment tsd-typography"><p>The only distinction between a TreeMultiSet and a BST lies in the ability of the former to store duplicate nodes through the utilization of counters.</p>
20
+ </div>
21
+ <div class="tsd-comment tsd-typography"></div></section>
18
22
  <section class="tsd-panel">
19
23
  <h4>Type Parameters</h4>
20
24
  <ul class="tsd-type-parameter-list">
21
25
  <li>
22
- <h4><span class="tsd-kind-type-parameter">T</span></h4></li></ul></section>
26
+ <h4><span class="tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol"> extends </span><a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">&gt;</span> = <a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">&gt;</span></h4></li></ul></section>
23
27
  <section class="tsd-panel tsd-hierarchy">
24
28
  <h4>Hierarchy</h4>
25
29
  <ul class="tsd-hierarchy">
26
- <li><a href="BST.html" class="tsd-signature-type tsd-kind-class">BST</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span>
30
+ <li><a href="BST.html" class="tsd-signature-type tsd-kind-class">BST</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">&gt;</span>
31
+ <ul class="tsd-hierarchy">
32
+ <li><span class="target">TreeMultiSet</span></li></ul></li></ul></section>
33
+ <section class="tsd-panel">
34
+ <h4>Implements</h4>
27
35
  <ul class="tsd-hierarchy">
28
- <li><span class="target">TreeMultiSet</span></li></ul></li></ul></section><aside class="tsd-sources">
36
+ <li><a href="../interfaces/IBinaryTree.html" class="tsd-signature-type tsd-kind-interface">IBinaryTree</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">&gt;</span></li></ul></section><aside class="tsd-sources">
29
37
  <ul>
30
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/tree-multiset.ts#L11">src/data-structures/binary-tree/tree-multiset.ts:11</a></li></ul></aside>
38
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/tree-multiset.ts#L19">src/data-structures/binary-tree/tree-multiset.ts:19</a></li></ul></aside>
31
39
  <section class="tsd-panel-group tsd-index-group">
32
40
  <section class="tsd-panel tsd-index-panel">
33
41
  <details class="tsd-index-content tsd-index-accordion" open><summary class="tsd-accordion-summary tsd-index-summary">
@@ -35,7 +43,7 @@
35
43
  <div class="tsd-accordion-details">
36
44
  <section class="tsd-index-section">
37
45
  <h3 class="tsd-index-heading">Constructors</h3>
38
- <div class="tsd-index-list"><a href="TreeMultiSet.html#constructor" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><g id="icon-512"><rect fill="var(--color-icon-background)" stroke="#4D7FFF" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)"></path></g></svg><span>constructor</span></a>
46
+ <div class="tsd-index-list"><a href="TreeMultiSet.html#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><g id="icon-512"><rect fill="var(--color-icon-background)" stroke="#4D7FFF" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)"></path></g></svg><span>constructor</span></a>
39
47
  </div></section>
40
48
  <section class="tsd-index-section">
41
49
  <h3 class="tsd-index-heading">Properties</h3>
@@ -63,6 +71,7 @@
63
71
  <a href="TreeMultiSet.html#DFSIterative" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>DFSIterative</span></a>
64
72
  <a href="TreeMultiSet.html#_accumulatedByPropertyName" class="tsd-index-link tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_accumulated<wbr/>By<wbr/>Property<wbr/>Name</span></a>
65
73
  <a href="TreeMultiSet.html#_compare" class="tsd-index-link tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_compare</span></a>
74
+ <a href="TreeMultiSet.html#_createNode" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_create<wbr/>Node</span></a>
66
75
  <a href="TreeMultiSet.html#_getResultByPropertyName" class="tsd-index-link tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_get<wbr/>Result<wbr/>By<wbr/>Property<wbr/>Name</span></a>
67
76
  <a href="TreeMultiSet.html#_pushByPropertyNameStopOrNot" class="tsd-index-link tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_push<wbr/>By<wbr/>Property<wbr/>Name<wbr/>Stop<wbr/>Or<wbr/>Not</span></a>
68
77
  <a href="TreeMultiSet.html#_resetResults" class="tsd-index-link tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_reset<wbr/>Results</span></a>
@@ -77,13 +86,12 @@
77
86
  <a href="TreeMultiSet.html#_setVisitedLeftSum" class="tsd-index-link tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_set<wbr/>Visited<wbr/>Left<wbr/>Sum</span></a>
78
87
  <a href="TreeMultiSet.html#_setVisitedNode" class="tsd-index-link tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_set<wbr/>Visited<wbr/>Node</span></a>
79
88
  <a href="TreeMultiSet.html#_setVisitedVal" class="tsd-index-link tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_set<wbr/>Visited<wbr/>Val</span></a>
80
- <a href="TreeMultiSet.html#add" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>add</span></a>
89
+ <a href="TreeMultiSet.html#add" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>add</span></a>
81
90
  <a href="TreeMultiSet.html#addMany" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>add<wbr/>Many</span></a>
82
91
  <a href="TreeMultiSet.html#addTo" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>add<wbr/>To</span></a>
83
92
  <a href="TreeMultiSet.html#allGreaterNodesAdd" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>all<wbr/>Greater<wbr/>Nodes<wbr/>Add</span></a>
84
93
  <a href="TreeMultiSet.html#balance" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>balance</span></a>
85
94
  <a href="TreeMultiSet.html#clear" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>clear</span></a>
86
- <a href="TreeMultiSet.html#createNode" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>create<wbr/>Node</span></a>
87
95
  <a href="TreeMultiSet.html#fill" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>fill</span></a>
88
96
  <a href="TreeMultiSet.html#get" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>get</span></a>
89
97
  <a href="TreeMultiSet.html#getDepth" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>get<wbr/>Depth</span></a>
@@ -105,43 +113,32 @@
105
113
  <a href="TreeMultiSet.html#levelIterative" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>level<wbr/>Iterative</span></a>
106
114
  <a href="TreeMultiSet.html#listLevels" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>list<wbr/>Levels</span></a>
107
115
  <a href="TreeMultiSet.html#morris" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>morris</span></a>
108
- <a href="TreeMultiSet.html#remove" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>remove</span></a>
116
+ <a href="TreeMultiSet.html#remove" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>remove</span></a>
109
117
  <a href="TreeMultiSet.html#setVisitedCount" class="tsd-index-link tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>set<wbr/>Visited<wbr/>Count</span></a>
110
118
  <a href="TreeMultiSet.html#subTreeAdd" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>sub<wbr/>Tree<wbr/>Add</span></a>
111
119
  <a href="TreeMultiSet.html#subTreeSum" class="tsd-index-link tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>sub<wbr/>Tree<wbr/>Sum</span></a>
112
120
  </div></section></div></details></section></section>
113
121
  <section class="tsd-panel-group tsd-member-group">
114
122
  <h2>Constructors</h2>
115
- <section class="tsd-panel tsd-member tsd-is-inherited"><a id="constructor" class="tsd-anchor"></a>
123
+ <section class="tsd-panel tsd-member"><a id="constructor" class="tsd-anchor"></a>
116
124
  <h3 class="tsd-anchor-link"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><g stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round" id="icon-anchor"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M10 14a3.5 3.5 0 0 0 5 0l4 -4a3.5 3.5 0 0 0 -5 -5l-.5 .5"></path><path d="M14 10a3.5 3.5 0 0 0 -5 0l-4 4a3.5 3.5 0 0 0 5 5l.5 -.5"></path></g></svg></a></h3>
117
- <ul class="tsd-signatures tsd-is-inherited">
118
- <li class="tsd-signature tsd-anchor-link" id="constructor.new_TreeMultiSet"><span class="tsd-kind-constructor-signature">new <wbr/>Tree<wbr/>Multi<wbr/>Set</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">options</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="TreeMultiSet.html" class="tsd-signature-type tsd-kind-class">TreeMultiSet</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><a href="#constructor.new_TreeMultiSet" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
125
+ <ul class="tsd-signatures">
126
+ <li class="tsd-signature tsd-anchor-link" id="constructor.new_TreeMultiSet"><span class="tsd-kind-constructor-signature">new <wbr/>Tree<wbr/>Multi<wbr/>Set</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">options</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="TreeMultiSet.html" class="tsd-signature-type tsd-kind-class">TreeMultiSet</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">&gt;</span><a href="#constructor.new_TreeMultiSet" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
119
127
  <li class="tsd-description">
120
- <div class="tsd-comment tsd-typography"><p>The constructor function accepts an optional options object and sets the comparator property if provided.</p>
121
- </div>
122
128
  <section class="tsd-panel">
123
129
  <h4>Type Parameters</h4>
124
130
  <ul class="tsd-type-parameter-list">
125
131
  <li>
126
- <h4><span class="tsd-kind-type-parameter">T</span></h4></li></ul></section>
132
+ <h4><span class="tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol"> extends </span><a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">, </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">&gt;</span> = <a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">, </span><a href="../types/RecursiveBSTNode.html" class="tsd-signature-type tsd-kind-type-alias">RecursiveBSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">&gt;</span></h4></li></ul></section>
127
133
  <div class="tsd-parameters">
128
134
  <h4 class="tsd-parameters-title">Parameters</h4>
129
135
  <ul class="tsd-parameter-list">
130
136
  <li>
131
- <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">options</span>: <span class="tsd-signature-symbol">{ </span><br/><span>    </span><span class="tsd-kind-property">comparator</span><span class="tsd-signature-symbol">?: </span><a href="../types/BSTComparator.html" class="tsd-signature-type tsd-kind-type-alias">BSTComparator</a><span class="tsd-signature-symbol">; </span><br/><span>    </span><span class="tsd-kind-property">loopType</span><span class="tsd-signature-symbol">?: </span><a href="../enums/LoopType.html" class="tsd-signature-type tsd-kind-enum">LoopType</a><span class="tsd-signature-symbol">; </span><br/><span class="tsd-signature-symbol">}</span></h5>
132
- <div class="tsd-comment tsd-typography"><p>An optional object that can contain the following properties:</p>
133
- </div>
134
- <div class="tsd-comment tsd-typography"></div>
135
- <ul class="tsd-parameters">
136
- <li class="tsd-parameter">
137
- <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-property">comparator</span><span class="tsd-signature-symbol">?: </span><a href="../types/BSTComparator.html" class="tsd-signature-type tsd-kind-type-alias">BSTComparator</a></h5></li>
138
- <li class="tsd-parameter">
139
- <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-property">loop<wbr/>Type</span><span class="tsd-signature-symbol">?: </span><a href="../enums/LoopType.html" class="tsd-signature-type tsd-kind-enum">LoopType</a></h5></li></ul></li></ul></div>
140
- <h4 class="tsd-returns-title">Returns <a href="TreeMultiSet.html" class="tsd-signature-type tsd-kind-class">TreeMultiSet</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4>
141
- <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
142
- <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#constructor">constructor</a></p>
137
+ <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">options</span>: <a href="../types/TreeMultiSetOptions.html" class="tsd-signature-type tsd-kind-type-alias">TreeMultiSetOptions</a></h5></li></ul></div>
138
+ <h4 class="tsd-returns-title">Returns <a href="TreeMultiSet.html" class="tsd-signature-type tsd-kind-class">TreeMultiSet</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources">
139
+ <p>Overrides <a href="BST.html">BST</a>.<a href="BST.html#constructor">constructor</a></p>
143
140
  <ul>
144
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/bst.ts#L24">src/data-structures/binary-tree/bst.ts:24</a></li></ul></aside></li></ul></section></section>
141
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/tree-multiset.ts#L20">src/data-structures/binary-tree/tree-multiset.ts:20</a></li></ul></aside></li></ul></section></section>
145
142
  <section class="tsd-panel-group tsd-member-group">
146
143
  <h2>Properties</h2>
147
144
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_comparator" class="tsd-anchor"></a>
@@ -149,7 +146,7 @@
149
146
  <div class="tsd-signature"><span class="tsd-kind-property">_comparator</span><span class="tsd-signature-symbol">:</span> <a href="../types/BSTComparator.html" class="tsd-signature-type tsd-kind-type-alias">BSTComparator</a><span class="tsd-signature-symbol"> = ...</span></div><aside class="tsd-sources">
150
147
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_comparator">_comparator</a></p>
151
148
  <ul>
152
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/bst.ts#L479">src/data-structures/binary-tree/bst.ts:479</a></li></ul></aside></section></section>
149
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/bst.ts#L475">src/data-structures/binary-tree/bst.ts:475</a></li></ul></aside></section></section>
153
150
  <section class="tsd-panel-group tsd-member-group">
154
151
  <h2>Accessors</h2>
155
152
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="autoIncrementId" class="tsd-anchor"></a>
@@ -160,7 +157,7 @@
160
157
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources">
161
158
  <p>Inherited from BST.autoIncrementId</p>
162
159
  <ul>
163
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L211">src/data-structures/binary-tree/binary-tree.ts:211</a></li></ul></aside></li></ul></section>
160
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L207">src/data-structures/binary-tree/abstract-binary-tree.ts:207</a></li></ul></aside></li></ul></section>
164
161
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="count" class="tsd-anchor"></a>
165
162
  <h3 class="tsd-anchor-link"><span>count</span><a href="#count" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
166
163
  <ul class="tsd-signatures tsd-is-inherited">
@@ -169,7 +166,7 @@
169
166
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span></h4><aside class="tsd-sources">
170
167
  <p>Inherited from BST.count</p>
171
168
  <ul>
172
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L241">src/data-structures/binary-tree/binary-tree.ts:241</a></li></ul></aside></li></ul></section>
169
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L237">src/data-structures/binary-tree/abstract-binary-tree.ts:237</a></li></ul></aside></li></ul></section>
173
170
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="isDuplicatedVal" class="tsd-anchor"></a>
174
171
  <h3 class="tsd-anchor-link"><span>is<wbr/>Duplicated<wbr/>Val</span><a href="#isDuplicatedVal" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
175
172
  <ul class="tsd-signatures tsd-is-inherited">
@@ -178,7 +175,7 @@
178
175
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources">
179
176
  <p>Inherited from BST.isDuplicatedVal</p>
180
177
  <ul>
181
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L223">src/data-structures/binary-tree/binary-tree.ts:223</a></li></ul></aside></li></ul></section>
178
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L219">src/data-structures/binary-tree/abstract-binary-tree.ts:219</a></li></ul></aside></li></ul></section>
182
179
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="loopType" class="tsd-anchor"></a>
183
180
  <h3 class="tsd-anchor-link"><span>loop<wbr/>Type</span><a href="#loopType" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
184
181
  <ul class="tsd-signatures tsd-is-inherited">
@@ -187,7 +184,7 @@
187
184
  <h4 class="tsd-returns-title">Returns <a href="../enums/LoopType.html" class="tsd-signature-type tsd-kind-enum">LoopType</a></h4><aside class="tsd-sources">
188
185
  <p>Inherited from BST.loopType</p>
189
186
  <ul>
190
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L176">src/data-structures/binary-tree/binary-tree.ts:176</a></li></ul></aside></li></ul></section>
187
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L172">src/data-structures/binary-tree/abstract-binary-tree.ts:172</a></li></ul></aside></li></ul></section>
191
188
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="maxId" class="tsd-anchor"></a>
192
189
  <h3 class="tsd-anchor-link"><span>max<wbr/>Id</span><a href="#maxId" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
193
190
  <ul class="tsd-signatures tsd-is-inherited">
@@ -196,16 +193,16 @@
196
193
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span></h4><aside class="tsd-sources">
197
194
  <p>Inherited from BST.maxId</p>
198
195
  <ul>
199
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L217">src/data-structures/binary-tree/binary-tree.ts:217</a></li></ul></aside></li></ul></section>
196
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L213">src/data-structures/binary-tree/abstract-binary-tree.ts:213</a></li></ul></aside></li></ul></section>
200
197
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="root" class="tsd-anchor"></a>
201
198
  <h3 class="tsd-anchor-link"><span>root</span><a href="#root" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
202
199
  <ul class="tsd-signatures tsd-is-inherited">
203
- <li class="tsd-signature" id="root.root-1"><span class="tsd-signature-symbol">get</span> root<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></li>
200
+ <li class="tsd-signature" id="root.root-1"><span class="tsd-signature-symbol">get</span> root<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></li>
204
201
  <li class="tsd-description">
205
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources">
202
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h4><aside class="tsd-sources">
206
203
  <p>Inherited from BST.root</p>
207
204
  <ul>
208
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L229">src/data-structures/binary-tree/binary-tree.ts:229</a></li></ul></aside></li></ul></section>
205
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L225">src/data-structures/binary-tree/abstract-binary-tree.ts:225</a></li></ul></aside></li></ul></section>
209
206
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="size" class="tsd-anchor"></a>
210
207
  <h3 class="tsd-anchor-link"><span>size</span><a href="#size" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
211
208
  <ul class="tsd-signatures tsd-is-inherited">
@@ -214,7 +211,7 @@
214
211
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span></h4><aside class="tsd-sources">
215
212
  <p>Inherited from BST.size</p>
216
213
  <ul>
217
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L235">src/data-structures/binary-tree/binary-tree.ts:235</a></li></ul></aside></li></ul></section>
214
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L231">src/data-structures/binary-tree/abstract-binary-tree.ts:231</a></li></ul></aside></li></ul></section>
218
215
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="visitedCount" class="tsd-anchor"></a>
219
216
  <h3 class="tsd-anchor-link"><span>visited<wbr/>Count</span><a href="#visitedCount" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
220
217
  <ul class="tsd-signatures tsd-is-inherited">
@@ -223,7 +220,7 @@
223
220
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><aside class="tsd-sources">
224
221
  <p>Inherited from BST.visitedCount</p>
225
222
  <ul>
226
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L199">src/data-structures/binary-tree/binary-tree.ts:199</a></li></ul></aside></li></ul></section>
223
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L195">src/data-structures/binary-tree/abstract-binary-tree.ts:195</a></li></ul></aside></li></ul></section>
227
224
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="visitedId" class="tsd-anchor"></a>
228
225
  <h3 class="tsd-anchor-link"><span>visited<wbr/>Id</span><a href="#visitedId" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
229
226
  <ul class="tsd-signatures tsd-is-inherited">
@@ -232,7 +229,7 @@
232
229
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><aside class="tsd-sources">
233
230
  <p>Inherited from BST.visitedId</p>
234
231
  <ul>
235
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L181">src/data-structures/binary-tree/binary-tree.ts:181</a></li></ul></aside></li></ul></section>
232
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L177">src/data-structures/binary-tree/abstract-binary-tree.ts:177</a></li></ul></aside></li></ul></section>
236
233
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="visitedLeftSum" class="tsd-anchor"></a>
237
234
  <h3 class="tsd-anchor-link"><span>visited<wbr/>Left<wbr/>Sum</span><a href="#visitedLeftSum" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
238
235
  <ul class="tsd-signatures tsd-is-inherited">
@@ -241,25 +238,25 @@
241
238
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><aside class="tsd-sources">
242
239
  <p>Inherited from BST.visitedLeftSum</p>
243
240
  <ul>
244
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L205">src/data-structures/binary-tree/binary-tree.ts:205</a></li></ul></aside></li></ul></section>
241
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L201">src/data-structures/binary-tree/abstract-binary-tree.ts:201</a></li></ul></aside></li></ul></section>
245
242
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="visitedNode" class="tsd-anchor"></a>
246
243
  <h3 class="tsd-anchor-link"><span>visited<wbr/>Node</span><a href="#visitedNode" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
247
244
  <ul class="tsd-signatures tsd-is-inherited">
248
- <li class="tsd-signature" id="visitedNode.visitedNode-1"><span class="tsd-signature-symbol">get</span> visitedNode<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></li>
245
+ <li class="tsd-signature" id="visitedNode.visitedNode-1"><span class="tsd-signature-symbol">get</span> visitedNode<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></li>
249
246
  <li class="tsd-description">
250
- <h4 class="tsd-returns-title">Returns <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h4><aside class="tsd-sources">
247
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h4><aside class="tsd-sources">
251
248
  <p>Inherited from BST.visitedNode</p>
252
249
  <ul>
253
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L193">src/data-structures/binary-tree/binary-tree.ts:193</a></li></ul></aside></li></ul></section>
250
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L189">src/data-structures/binary-tree/abstract-binary-tree.ts:189</a></li></ul></aside></li></ul></section>
254
251
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="visitedVal" class="tsd-anchor"></a>
255
252
  <h3 class="tsd-anchor-link"><span>visited<wbr/>Val</span><a href="#visitedVal" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
256
253
  <ul class="tsd-signatures tsd-is-inherited">
257
- <li class="tsd-signature" id="visitedVal.visitedVal-1"><span class="tsd-signature-symbol">get</span> visitedVal<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span></li>
254
+ <li class="tsd-signature" id="visitedVal.visitedVal-1"><span class="tsd-signature-symbol">get</span> visitedVal<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></li>
258
255
  <li class="tsd-description">
259
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span></h4><aside class="tsd-sources">
256
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></h4><aside class="tsd-sources">
260
257
  <p>Inherited from BST.visitedVal</p>
261
258
  <ul>
262
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L187">src/data-structures/binary-tree/binary-tree.ts:187</a></li></ul></aside></li></ul></section></section>
259
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L183">src/data-structures/binary-tree/abstract-binary-tree.ts:183</a></li></ul></aside></li></ul></section></section>
263
260
  <section class="tsd-panel-group tsd-member-group">
264
261
  <h2>Methods</h2>
265
262
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="BFS" class="tsd-anchor"></a>
@@ -270,12 +267,12 @@
270
267
  <div class="tsd-comment tsd-typography"><p>The BFS function performs a breadth-first search on a binary tree and returns the results based on a specified node
271
268
  or property name.</p>
272
269
  </div>
273
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
270
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
274
271
 
275
272
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
276
273
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#BFS">BFS</a></p>
277
274
  <ul>
278
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L941">src/data-structures/binary-tree/binary-tree.ts:941</a></li></ul></aside></li>
275
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L937">src/data-structures/binary-tree/abstract-binary-tree.ts:937</a></li></ul></aside></li>
279
276
  <li class="tsd-signature tsd-anchor-link" id="BFS.BFS-2"><span class="tsd-kind-call-signature">BFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><a href="#BFS.BFS-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
280
277
  <li class="tsd-description">
281
278
  <div class="tsd-comment tsd-typography"><p>The BFS function performs a breadth-first search on a binary tree and returns the results based on a specified node
@@ -292,13 +289,13 @@ performed starting from that node. If a property name is provided, the breadth-f
292
289
  performed starting from the root node</p>
293
290
  </div>
294
291
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
295
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
292
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
296
293
 
297
294
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
298
295
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#BFS">BFS</a></p>
299
296
  <ul>
300
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L943">src/data-structures/binary-tree/binary-tree.ts:943</a></li></ul></aside></li>
301
- <li class="tsd-signature tsd-anchor-link" id="BFS.BFS-3"><span class="tsd-kind-call-signature">BFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span><a href="#BFS.BFS-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
297
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L939">src/data-structures/binary-tree/abstract-binary-tree.ts:939</a></li></ul></aside></li>
298
+ <li class="tsd-signature tsd-anchor-link" id="BFS.BFS-3"><span class="tsd-kind-call-signature">BFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><a href="#BFS.BFS-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
302
299
  <li class="tsd-description">
303
300
  <div class="tsd-comment tsd-typography"><p>The BFS function performs a breadth-first search on a binary tree and returns the results based on a specified node
304
301
  or property name.</p>
@@ -314,13 +311,13 @@ performed starting from that node. If a property name is provided, the breadth-f
314
311
  performed starting from the root node</p>
315
312
  </div>
316
313
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
317
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
314
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
318
315
 
319
316
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
320
317
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#BFS">BFS</a></p>
321
318
  <ul>
322
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L945">src/data-structures/binary-tree/binary-tree.ts:945</a></li></ul></aside></li>
323
- <li class="tsd-signature tsd-anchor-link" id="BFS.BFS-4"><span class="tsd-kind-call-signature">BFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span><a href="#BFS.BFS-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
319
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L941">src/data-structures/binary-tree/abstract-binary-tree.ts:941</a></li></ul></aside></li>
320
+ <li class="tsd-signature tsd-anchor-link" id="BFS.BFS-4"><span class="tsd-kind-call-signature">BFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><a href="#BFS.BFS-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
324
321
  <li class="tsd-description">
325
322
  <div class="tsd-comment tsd-typography"><p>The BFS function performs a breadth-first search on a binary tree and returns the results based on a specified node
326
323
  or property name.</p>
@@ -336,12 +333,12 @@ performed starting from that node. If a property name is provided, the breadth-f
336
333
  performed starting from the root node</p>
337
334
  </div>
338
335
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
339
- <h4 class="tsd-returns-title">Returns <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
336
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
340
337
 
341
338
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
342
339
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#BFS">BFS</a></p>
343
340
  <ul>
344
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L947">src/data-structures/binary-tree/binary-tree.ts:947</a></li></ul></aside></li>
341
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L943">src/data-structures/binary-tree/abstract-binary-tree.ts:943</a></li></ul></aside></li>
345
342
  <li class="tsd-signature tsd-anchor-link" id="BFS.BFS-5"><span class="tsd-kind-call-signature">BFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><a href="#BFS.BFS-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
346
343
  <li class="tsd-description">
347
344
  <div class="tsd-comment tsd-typography"><p>The BFS function performs a breadth-first search on a binary tree and returns the results based on a specified node
@@ -358,12 +355,12 @@ performed starting from that node. If a property name is provided, the breadth-f
358
355
  performed starting from the root node</p>
359
356
  </div>
360
357
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
361
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
358
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
362
359
 
363
360
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
364
361
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#BFS">BFS</a></p>
365
362
  <ul>
366
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L949">src/data-structures/binary-tree/binary-tree.ts:949</a></li></ul></aside></li></ul></section>
363
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L945">src/data-structures/binary-tree/abstract-binary-tree.ts:945</a></li></ul></aside></li></ul></section>
367
364
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="DFS" class="tsd-anchor"></a>
368
365
  <h3 class="tsd-anchor-link"><span>DFS</span><a href="#DFS" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
369
366
  <ul class="tsd-signatures tsd-is-inherited">
@@ -372,12 +369,12 @@ performed starting from the root node</p>
372
369
  <div class="tsd-comment tsd-typography"><p>The DFS function performs a depth-first search traversal on a binary tree and returns the results based on the
373
370
  specified pattern and node or property name.</p>
374
371
  </div>
375
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
372
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
376
373
 
377
374
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
378
375
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#DFS">DFS</a></p>
379
376
  <ul>
380
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L977">src/data-structures/binary-tree/binary-tree.ts:977</a></li></ul></aside></li>
377
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L973">src/data-structures/binary-tree/abstract-binary-tree.ts:973</a></li></ul></aside></li>
381
378
  <li class="tsd-signature tsd-anchor-link" id="DFS.DFS-2"><span class="tsd-kind-call-signature">DFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><a href="#DFS.DFS-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
382
379
  <li class="tsd-description">
383
380
  <div class="tsd-comment tsd-typography"><p>The DFS function performs a depth-first search traversal on a binary tree and returns the results based on the
@@ -401,13 +398,13 @@ either the name of a property in the <code>BinaryTreeNode</code> object or the v
401
398
  no value</p>
402
399
  </div>
403
400
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
404
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
401
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
405
402
 
406
403
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
407
404
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#DFS">DFS</a></p>
408
405
  <ul>
409
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L979">src/data-structures/binary-tree/binary-tree.ts:979</a></li></ul></aside></li>
410
- <li class="tsd-signature tsd-anchor-link" id="DFS.DFS-3"><span class="tsd-kind-call-signature">DFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span><a href="#DFS.DFS-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
406
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L975">src/data-structures/binary-tree/abstract-binary-tree.ts:975</a></li></ul></aside></li>
407
+ <li class="tsd-signature tsd-anchor-link" id="DFS.DFS-3"><span class="tsd-kind-call-signature">DFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><a href="#DFS.DFS-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
411
408
  <li class="tsd-description">
412
409
  <div class="tsd-comment tsd-typography"><p>The DFS function performs a depth-first search traversal on a binary tree and returns the results based on the
413
410
  specified pattern and node or property name.</p>
@@ -430,13 +427,13 @@ either the name of a property in the <code>BinaryTreeNode</code> object or the v
430
427
  no value</p>
431
428
  </div>
432
429
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
433
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
430
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
434
431
 
435
432
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
436
433
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#DFS">DFS</a></p>
437
434
  <ul>
438
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L981">src/data-structures/binary-tree/binary-tree.ts:981</a></li></ul></aside></li>
439
- <li class="tsd-signature tsd-anchor-link" id="DFS.DFS-4"><span class="tsd-kind-call-signature">DFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span><a href="#DFS.DFS-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
435
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L977">src/data-structures/binary-tree/abstract-binary-tree.ts:977</a></li></ul></aside></li>
436
+ <li class="tsd-signature tsd-anchor-link" id="DFS.DFS-4"><span class="tsd-kind-call-signature">DFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><a href="#DFS.DFS-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
440
437
  <li class="tsd-description">
441
438
  <div class="tsd-comment tsd-typography"><p>The DFS function performs a depth-first search traversal on a binary tree and returns the results based on the
442
439
  specified pattern and node or property name.</p>
@@ -459,12 +456,12 @@ either the name of a property in the <code>BinaryTreeNode</code> object or the v
459
456
  no value</p>
460
457
  </div>
461
458
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
462
- <h4 class="tsd-returns-title">Returns <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
459
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
463
460
 
464
461
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
465
462
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#DFS">DFS</a></p>
466
463
  <ul>
467
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L983">src/data-structures/binary-tree/binary-tree.ts:983</a></li></ul></aside></li>
464
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L979">src/data-structures/binary-tree/abstract-binary-tree.ts:979</a></li></ul></aside></li>
468
465
  <li class="tsd-signature tsd-anchor-link" id="DFS.DFS-5"><span class="tsd-kind-call-signature">DFS</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><a href="#DFS.DFS-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
469
466
  <li class="tsd-description">
470
467
  <div class="tsd-comment tsd-typography"><p>The DFS function performs a depth-first search traversal on a binary tree and returns the results based on the
@@ -488,12 +485,12 @@ either the name of a property in the <code>BinaryTreeNode</code> object or the v
488
485
  no value</p>
489
486
  </div>
490
487
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
491
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
488
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
492
489
 
493
490
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
494
491
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#DFS">DFS</a></p>
495
492
  <ul>
496
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L985">src/data-structures/binary-tree/binary-tree.ts:985</a></li></ul></aside></li></ul></section>
493
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L981">src/data-structures/binary-tree/abstract-binary-tree.ts:981</a></li></ul></aside></li></ul></section>
497
494
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="DFSIterative" class="tsd-anchor"></a>
498
495
  <h3 class="tsd-anchor-link"><span>DFSIterative</span><a href="#DFSIterative" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
499
496
  <ul class="tsd-signatures tsd-is-inherited">
@@ -506,7 +503,7 @@ Space complexity of Iterative DFS equals to recursive DFS which is O(n) because
506
503
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
507
504
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#DFSIterative">DFSIterative</a></p>
508
505
  <ul>
509
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1027">src/data-structures/binary-tree/binary-tree.ts:1027</a></li></ul></aside></li>
506
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1023">src/data-structures/binary-tree/abstract-binary-tree.ts:1023</a></li></ul></aside></li>
510
507
  <li class="tsd-signature tsd-anchor-link" id="DFSIterative.DFSIterative-2"><span class="tsd-kind-call-signature">DFSIterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><a href="#DFSIterative.DFSIterative-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
511
508
  <li class="tsd-description">
512
509
  <div class="tsd-comment tsd-typography"><p>Time complexity is O(n)
@@ -525,8 +522,8 @@ Space complexity of Iterative DFS equals to recursive DFS which is O(n) because
525
522
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
526
523
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#DFSIterative">DFSIterative</a></p>
527
524
  <ul>
528
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1029">src/data-structures/binary-tree/binary-tree.ts:1029</a></li></ul></aside></li>
529
- <li class="tsd-signature tsd-anchor-link" id="DFSIterative.DFSIterative-3"><span class="tsd-kind-call-signature">DFSIterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span><a href="#DFSIterative.DFSIterative-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
525
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1025">src/data-structures/binary-tree/abstract-binary-tree.ts:1025</a></li></ul></aside></li>
526
+ <li class="tsd-signature tsd-anchor-link" id="DFSIterative.DFSIterative-3"><span class="tsd-kind-call-signature">DFSIterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><a href="#DFSIterative.DFSIterative-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
530
527
  <li class="tsd-description">
531
528
  <div class="tsd-comment tsd-typography"><p>Time complexity is O(n)
532
529
  Space complexity of Iterative DFS equals to recursive DFS which is O(n) because of the stack</p>
@@ -540,12 +537,12 @@ Space complexity of Iterative DFS equals to recursive DFS which is O(n) because
540
537
  <li>
541
538
  <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">nodeOrPropertyName</span>: <span class="tsd-signature-type">&quot;val&quot;</span></h5>
542
539
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
543
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span></h4>
540
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h4>
544
541
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
545
542
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#DFSIterative">DFSIterative</a></p>
546
543
  <ul>
547
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1031">src/data-structures/binary-tree/binary-tree.ts:1031</a></li></ul></aside></li>
548
- <li class="tsd-signature tsd-anchor-link" id="DFSIterative.DFSIterative-4"><span class="tsd-kind-call-signature">DFSIterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span><a href="#DFSIterative.DFSIterative-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
544
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1027">src/data-structures/binary-tree/abstract-binary-tree.ts:1027</a></li></ul></aside></li>
545
+ <li class="tsd-signature tsd-anchor-link" id="DFSIterative.DFSIterative-4"><span class="tsd-kind-call-signature">DFSIterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><a href="#DFSIterative.DFSIterative-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
549
546
  <li class="tsd-description">
550
547
  <div class="tsd-comment tsd-typography"><p>Time complexity is O(n)
551
548
  Space complexity of Iterative DFS equals to recursive DFS which is O(n) because of the stack</p>
@@ -559,11 +556,11 @@ Space complexity of Iterative DFS equals to recursive DFS which is O(n) because
559
556
  <li>
560
557
  <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">nodeOrPropertyName</span>: <span class="tsd-signature-type">&quot;node&quot;</span></h5>
561
558
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
562
- <h4 class="tsd-returns-title">Returns <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h4>
559
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h4>
563
560
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
564
561
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#DFSIterative">DFSIterative</a></p>
565
562
  <ul>
566
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1033">src/data-structures/binary-tree/binary-tree.ts:1033</a></li></ul></aside></li>
563
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1029">src/data-structures/binary-tree/abstract-binary-tree.ts:1029</a></li></ul></aside></li>
567
564
  <li class="tsd-signature tsd-anchor-link" id="DFSIterative.DFSIterative-5"><span class="tsd-kind-call-signature">DFSIterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><a href="#DFSIterative.DFSIterative-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
568
565
  <li class="tsd-description">
569
566
  <div class="tsd-comment tsd-typography"><p>Time complexity is O(n)
@@ -582,7 +579,7 @@ Space complexity of Iterative DFS equals to recursive DFS which is O(n) because
582
579
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
583
580
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#DFSIterative">DFSIterative</a></p>
584
581
  <ul>
585
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1035">src/data-structures/binary-tree/binary-tree.ts:1035</a></li></ul></aside></li></ul></section>
582
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1031">src/data-structures/binary-tree/abstract-binary-tree.ts:1031</a></li></ul></aside></li></ul></section>
586
583
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_accumulatedByPropertyName" class="tsd-anchor"></a>
587
584
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_accumulated<wbr/>By<wbr/>Property<wbr/>Name</span><a href="#_accumulatedByPropertyName" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
588
585
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -595,8 +592,8 @@ provided property name or a default property name.</p>
595
592
  <h4 class="tsd-parameters-title">Parameters</h4>
596
593
  <ul class="tsd-parameter-list">
597
594
  <li>
598
- <h5><span class="tsd-kind-parameter">node</span>: <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
599
- <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is of type <code>BinaryTreeNode&lt;T&gt;</code>, which represents a node in a binary tree.</p>
595
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
596
+ <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is of type <code>N</code>, which represents a node in a binary tree.</p>
600
597
  </div>
601
598
  <div class="tsd-comment tsd-typography"></div></li>
602
599
  <li>
@@ -610,7 +607,7 @@ the property name of the node that should be accumulated. If it is a node object
610
607
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
611
608
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_accumulatedByPropertyName">_accumulatedByPropertyName</a></p>
612
609
  <ul>
613
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1447">src/data-structures/binary-tree/binary-tree.ts:1447</a></li></ul></aside></li></ul></section>
610
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1443">src/data-structures/binary-tree/abstract-binary-tree.ts:1443</a></li></ul></aside></li></ul></section>
614
611
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_compare" class="tsd-anchor"></a>
615
612
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_compare</span><a href="#_compare" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
616
613
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -638,11 +635,45 @@ than), or CP.eq (equal).</p>
638
635
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
639
636
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_compare">_compare</a></p>
640
637
  <ul>
641
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/bst.ts#L489">src/data-structures/binary-tree/bst.ts:489</a></li></ul></aside></li></ul></section>
638
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/bst.ts#L485">src/data-structures/binary-tree/bst.ts:485</a></li></ul></aside></li></ul></section>
639
+ <section class="tsd-panel tsd-member"><a id="_createNode" class="tsd-anchor"></a>
640
+ <h3 class="tsd-anchor-link"><span>_create<wbr/>Node</span><a href="#_createNode" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
641
+ <ul class="tsd-signatures">
642
+ <li class="tsd-signature tsd-anchor-link" id="_createNode._createNode-1"><span class="tsd-kind-call-signature">_create<wbr/>Node</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">id</span>, <span class="tsd-kind-parameter">val</span>, <span class="tsd-kind-parameter">count</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><a href="#_createNode._createNode-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
643
+ <li class="tsd-description">
644
+ <div class="tsd-comment tsd-typography"><p>The function creates a new BSTNode with the given id, value, and count.</p>
645
+ </div>
646
+ <div class="tsd-parameters">
647
+ <h4 class="tsd-parameters-title">Parameters</h4>
648
+ <ul class="tsd-parameter-list">
649
+ <li>
650
+ <h5><span class="tsd-kind-parameter">id</span>: <span class="tsd-signature-type">number</span></h5>
651
+ <div class="tsd-comment tsd-typography"><p>The id parameter is the unique identifier for the binary tree node. It is used to
652
+ distinguish one node from another in the tree.</p>
653
+ </div>
654
+ <div class="tsd-comment tsd-typography"></div></li>
655
+ <li>
656
+ <h5><span class="tsd-kind-parameter">val</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span></h5>
657
+ <div class="tsd-comment tsd-typography"><p>The <code>val</code> parameter represents the value that will be stored in the binary search tree node.</p>
658
+ </div>
659
+ <div class="tsd-comment tsd-typography"></div></li>
660
+ <li>
661
+ <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">count</span>: <span class="tsd-signature-type">number</span></h5>
662
+ <div class="tsd-comment tsd-typography"><p>The &quot;count&quot; parameter is an optional parameter of type number. It represents the number of
663
+ occurrences of the value in the binary search tree node. If not provided, the count will default to 1.</p>
664
+ </div>
665
+ <div class="tsd-comment tsd-typography"></div></li></ul></div>
666
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h4><p>A new instance of the BSTNode class with the specified id, value, and count (if provided).</p>
667
+
668
+ <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
669
+ <p>Implementation of <a href="../interfaces/IBinaryTree.html">IBinaryTree</a>.<a href="../interfaces/IBinaryTree.html#_createNode">_createNode</a></p>
670
+ <p>Overrides <a href="BST.html">BST</a>.<a href="BST.html#_createNode">_createNode</a></p>
671
+ <ul>
672
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/tree-multiset.ts#L33">src/data-structures/binary-tree/tree-multiset.ts:33</a></li></ul></aside></li></ul></section>
642
673
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_getResultByPropertyName" class="tsd-anchor"></a>
643
674
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_get<wbr/>Result<wbr/>By<wbr/>Property<wbr/>Name</span><a href="#_getResultByPropertyName" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
644
675
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
645
- <li class="tsd-signature tsd-anchor-link" id="_getResultByPropertyName._getResultByPropertyName-1"><span class="tsd-kind-call-signature">_get<wbr/>Result<wbr/>By<wbr/>Property<wbr/>Name</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="../types/ResultsByProperty.html" class="tsd-signature-type tsd-kind-type-alias">ResultsByProperty</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><a href="#_getResultByPropertyName._getResultByPropertyName-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
676
+ <li class="tsd-signature tsd-anchor-link" id="_getResultByPropertyName._getResultByPropertyName-1"><span class="tsd-kind-call-signature">_get<wbr/>Result<wbr/>By<wbr/>Property<wbr/>Name</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="../types/AbstractResultsByProperty.html" class="tsd-signature-type tsd-kind-type-alias">AbstractResultsByProperty</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">&gt;</span><a href="#_getResultByPropertyName._getResultByPropertyName-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
646
677
  <li class="tsd-description">
647
678
  <div class="tsd-comment tsd-typography"><p>The function <code>_getResultByPropertyName</code> returns different results based on the provided property name or defaulting
648
679
  to &#39;id&#39;.</p>
@@ -656,12 +687,12 @@ to &#39;id&#39;.</p>
656
687
  can accept a value of type <code>NodeOrPropertyName</code>.</p>
657
688
  </div>
658
689
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
659
- <h4 class="tsd-returns-title">Returns <a href="../types/ResultsByProperty.html" class="tsd-signature-type tsd-kind-type-alias">ResultsByProperty</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The method returns an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
690
+ <h4 class="tsd-returns-title">Returns <a href="../types/AbstractResultsByProperty.html" class="tsd-signature-type tsd-kind-type-alias">AbstractResultsByProperty</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The method returns an object of type <code>AbstractResultsByProperty&lt;T&gt;</code>.</p>
660
691
 
661
692
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
662
693
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_getResultByPropertyName">_getResultByPropertyName</a></p>
663
694
  <ul>
664
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1476">src/data-structures/binary-tree/binary-tree.ts:1476</a></li></ul></aside></li></ul></section>
695
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1472">src/data-structures/binary-tree/abstract-binary-tree.ts:1472</a></li></ul></aside></li></ul></section>
665
696
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_pushByPropertyNameStopOrNot" class="tsd-anchor"></a>
666
697
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_push<wbr/>By<wbr/>Property<wbr/>Name<wbr/>Stop<wbr/>Or<wbr/>Not</span><a href="#_pushByPropertyNameStopOrNot" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
667
698
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -674,18 +705,18 @@ a result array.</p>
674
705
  <h4 class="tsd-parameters-title">Parameters</h4>
675
706
  <ul class="tsd-parameter-list">
676
707
  <li>
677
- <h5><span class="tsd-kind-parameter">cur</span>: <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
708
+ <h5><span class="tsd-kind-parameter">cur</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
678
709
  <div class="tsd-comment tsd-typography"><p>The current binary tree node that is being checked.</p>
679
710
  </div>
680
711
  <div class="tsd-comment tsd-typography"></div></li>
681
712
  <li>
682
- <h5><span class="tsd-kind-parameter">result</span>: <span class="tsd-signature-symbol">(</span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">[]</span></h5>
713
+ <h5><span class="tsd-kind-parameter">result</span>: <span class="tsd-signature-symbol">(</span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">[]</span></h5>
683
714
  <div class="tsd-comment tsd-typography"><p>An array that stores the matching nodes found during the
684
715
  traversal.</p>
685
716
  </div>
686
717
  <div class="tsd-comment tsd-typography"></div></li>
687
718
  <li>
688
- <h5><span class="tsd-kind-parameter">nodeProperty</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span></h5>
719
+ <h5><span class="tsd-kind-parameter">nodeProperty</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
689
720
  <div class="tsd-comment tsd-typography"><p>The <code>nodeProperty</code> parameter is the value that we are searching for in
690
721
  the binary tree nodes. It can be either the <code>id</code>, <code>count</code>, or <code>val</code> property of the node.</p>
691
722
  </div>
@@ -709,7 +740,7 @@ stop after finding the first matching node or continue searching for all matchin
709
740
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
710
741
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_pushByPropertyNameStopOrNot">_pushByPropertyNameStopOrNot</a></p>
711
742
  <ul>
712
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1410">src/data-structures/binary-tree/binary-tree.ts:1410</a></li></ul></aside></li></ul></section>
743
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1406">src/data-structures/binary-tree/abstract-binary-tree.ts:1406</a></li></ul></aside></li></ul></section>
713
744
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_resetResults" class="tsd-anchor"></a>
714
745
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_reset<wbr/>Results</span><a href="#_resetResults" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
715
746
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -721,7 +752,7 @@ stop after finding the first matching node or continue searching for all matchin
721
752
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
722
753
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_resetResults">_resetResults</a></p>
723
754
  <ul>
724
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1386">src/data-structures/binary-tree/binary-tree.ts:1386</a></li></ul></aside></li></ul></section>
755
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1382">src/data-structures/binary-tree/abstract-binary-tree.ts:1382</a></li></ul></aside></li></ul></section>
725
756
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_setAutoIncrementId" class="tsd-anchor"></a>
726
757
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_set<wbr/>Auto<wbr/>Increment<wbr/>Id</span><a href="#_setAutoIncrementId" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
727
758
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -735,7 +766,7 @@ stop after finding the first matching node or continue searching for all matchin
735
766
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
736
767
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_setAutoIncrementId">_setAutoIncrementId</a></p>
737
768
  <ul>
738
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1355">src/data-structures/binary-tree/binary-tree.ts:1355</a></li></ul></aside></li></ul></section>
769
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1351">src/data-structures/binary-tree/abstract-binary-tree.ts:1351</a></li></ul></aside></li></ul></section>
739
770
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_setCount" class="tsd-anchor"></a>
740
771
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_set<wbr/>Count</span><a href="#_setCount" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
741
772
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -749,7 +780,7 @@ stop after finding the first matching node or continue searching for all matchin
749
780
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
750
781
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_setCount">_setCount</a></p>
751
782
  <ul>
752
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1379">src/data-structures/binary-tree/binary-tree.ts:1379</a></li></ul></aside></li></ul></section>
783
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1375">src/data-structures/binary-tree/abstract-binary-tree.ts:1375</a></li></ul></aside></li></ul></section>
753
784
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_setIsDuplicatedVal" class="tsd-anchor"></a>
754
785
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_set<wbr/>Is<wbr/>Duplicated<wbr/>Val</span><a href="#_setIsDuplicatedVal" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
755
786
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -763,7 +794,7 @@ stop after finding the first matching node or continue searching for all matchin
763
794
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
764
795
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_setIsDuplicatedVal">_setIsDuplicatedVal</a></p>
765
796
  <ul>
766
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1363">src/data-structures/binary-tree/binary-tree.ts:1363</a></li></ul></aside></li></ul></section>
797
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1359">src/data-structures/binary-tree/abstract-binary-tree.ts:1359</a></li></ul></aside></li></ul></section>
767
798
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_setLoopType" class="tsd-anchor"></a>
768
799
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_set<wbr/>Loop<wbr/>Type</span><a href="#_setLoopType" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
769
800
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -777,7 +808,7 @@ stop after finding the first matching node or continue searching for all matchin
777
808
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
778
809
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_setLoopType">_setLoopType</a></p>
779
810
  <ul>
780
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1331">src/data-structures/binary-tree/binary-tree.ts:1331</a></li></ul></aside></li></ul></section>
811
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1327">src/data-structures/binary-tree/abstract-binary-tree.ts:1327</a></li></ul></aside></li></ul></section>
781
812
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_setMaxId" class="tsd-anchor"></a>
782
813
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_set<wbr/>Max<wbr/>Id</span><a href="#_setMaxId" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
783
814
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -791,7 +822,7 @@ stop after finding the first matching node or continue searching for all matchin
791
822
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
792
823
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_setMaxId">_setMaxId</a></p>
793
824
  <ul>
794
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1359">src/data-structures/binary-tree/binary-tree.ts:1359</a></li></ul></aside></li></ul></section>
825
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1355">src/data-structures/binary-tree/abstract-binary-tree.ts:1355</a></li></ul></aside></li></ul></section>
795
826
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_setRoot" class="tsd-anchor"></a>
796
827
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_set<wbr/>Root</span><a href="#_setRoot" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
797
828
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -801,11 +832,11 @@ stop after finding the first matching node or continue searching for all matchin
801
832
  <h4 class="tsd-parameters-title">Parameters</h4>
802
833
  <ul class="tsd-parameter-list">
803
834
  <li>
804
- <h5><span class="tsd-kind-parameter">v</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5></li></ul></div>
835
+ <h5><span class="tsd-kind-parameter">v</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5></li></ul></div>
805
836
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
806
837
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_setRoot">_setRoot</a></p>
807
838
  <ul>
808
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1367">src/data-structures/binary-tree/binary-tree.ts:1367</a></li></ul></aside></li></ul></section>
839
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1363">src/data-structures/binary-tree/abstract-binary-tree.ts:1363</a></li></ul></aside></li></ul></section>
809
840
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_setSize" class="tsd-anchor"></a>
810
841
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_set<wbr/>Size</span><a href="#_setSize" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
811
842
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -819,7 +850,7 @@ stop after finding the first matching node or continue searching for all matchin
819
850
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
820
851
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_setSize">_setSize</a></p>
821
852
  <ul>
822
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1375">src/data-structures/binary-tree/binary-tree.ts:1375</a></li></ul></aside></li></ul></section>
853
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1371">src/data-structures/binary-tree/abstract-binary-tree.ts:1371</a></li></ul></aside></li></ul></section>
823
854
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_setVisitedId" class="tsd-anchor"></a>
824
855
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_set<wbr/>Visited<wbr/>Id</span><a href="#_setVisitedId" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
825
856
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -833,7 +864,7 @@ stop after finding the first matching node or continue searching for all matchin
833
864
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
834
865
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_setVisitedId">_setVisitedId</a></p>
835
866
  <ul>
836
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1335">src/data-structures/binary-tree/binary-tree.ts:1335</a></li></ul></aside></li></ul></section>
867
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1331">src/data-structures/binary-tree/abstract-binary-tree.ts:1331</a></li></ul></aside></li></ul></section>
837
868
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_setVisitedLeftSum" class="tsd-anchor"></a>
838
869
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_set<wbr/>Visited<wbr/>Left<wbr/>Sum</span><a href="#_setVisitedLeftSum" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
839
870
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -847,7 +878,7 @@ stop after finding the first matching node or continue searching for all matchin
847
878
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
848
879
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_setVisitedLeftSum">_setVisitedLeftSum</a></p>
849
880
  <ul>
850
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1351">src/data-structures/binary-tree/binary-tree.ts:1351</a></li></ul></aside></li></ul></section>
881
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1347">src/data-structures/binary-tree/abstract-binary-tree.ts:1347</a></li></ul></aside></li></ul></section>
851
882
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_setVisitedNode" class="tsd-anchor"></a>
852
883
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_set<wbr/>Visited<wbr/>Node</span><a href="#_setVisitedNode" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
853
884
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -857,11 +888,11 @@ stop after finding the first matching node or continue searching for all matchin
857
888
  <h4 class="tsd-parameters-title">Parameters</h4>
858
889
  <ul class="tsd-parameter-list">
859
890
  <li>
860
- <h5><span class="tsd-kind-parameter">value</span>: <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h5></li></ul></div>
891
+ <h5><span class="tsd-kind-parameter">value</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h5></li></ul></div>
861
892
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
862
893
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_setVisitedNode">_setVisitedNode</a></p>
863
894
  <ul>
864
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1343">src/data-structures/binary-tree/binary-tree.ts:1343</a></li></ul></aside></li></ul></section>
895
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1339">src/data-structures/binary-tree/abstract-binary-tree.ts:1339</a></li></ul></aside></li></ul></section>
865
896
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="_setVisitedVal" class="tsd-anchor"></a>
866
897
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>_set<wbr/>Visited<wbr/>Val</span><a href="#_setVisitedVal" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
867
898
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -871,48 +902,51 @@ stop after finding the first matching node or continue searching for all matchin
871
902
  <h4 class="tsd-parameters-title">Parameters</h4>
872
903
  <ul class="tsd-parameter-list">
873
904
  <li>
874
- <h5><span class="tsd-kind-parameter">value</span>: <span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span></h5></li></ul></div>
905
+ <h5><span class="tsd-kind-parameter">value</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h5></li></ul></div>
875
906
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
876
907
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#_setVisitedVal">_setVisitedVal</a></p>
877
908
  <ul>
878
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1339">src/data-structures/binary-tree/binary-tree.ts:1339</a></li></ul></aside></li></ul></section>
879
- <section class="tsd-panel tsd-member"><a id="add" class="tsd-anchor"></a>
909
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1335">src/data-structures/binary-tree/abstract-binary-tree.ts:1335</a></li></ul></aside></li></ul></section>
910
+ <section class="tsd-panel tsd-member tsd-is-inherited"><a id="add" class="tsd-anchor"></a>
880
911
  <h3 class="tsd-anchor-link"><span>add</span><a href="#add" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
881
- <ul class="tsd-signatures">
882
- <li class="tsd-signature tsd-anchor-link" id="add.add-1"><span class="tsd-kind-call-signature">add</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">id</span>, <span class="tsd-kind-parameter">val</span>, <span class="tsd-kind-parameter">count</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><a href="#add.add-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
912
+ <ul class="tsd-signatures tsd-is-inherited">
913
+ <li class="tsd-signature tsd-anchor-link" id="add.add-1"><span class="tsd-kind-call-signature">add</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">id</span>, <span class="tsd-kind-parameter">val</span>, <span class="tsd-kind-parameter">count</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><a href="#add.add-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
883
914
  <li class="tsd-description">
884
- <div class="tsd-comment tsd-typography"><p>The function overrides the add method of the BinarySearchTree class in TypeScript.</p>
915
+ <div class="tsd-comment tsd-typography"><p>The <code>add</code> function inserts a new node into a binary search tree, updating the count and value of an existing node if
916
+ the ID matches, and returns the inserted node.</p>
885
917
  </div>
886
918
  <div class="tsd-parameters">
887
919
  <h4 class="tsd-parameters-title">Parameters</h4>
888
920
  <ul class="tsd-parameter-list">
889
921
  <li>
890
922
  <h5><span class="tsd-kind-parameter">id</span>: <span class="tsd-signature-type">number</span></h5>
891
- <div class="tsd-comment tsd-typography"><p>The <code>id</code> parameter is the identifier of the binary tree node that you want to add.</p>
923
+ <div class="tsd-comment tsd-typography"><p>The <code>id</code> parameter represents the identifier of the binary tree node. It is used to
924
+ determine the position of the node in the binary search tree.</p>
892
925
  </div>
893
926
  <div class="tsd-comment tsd-typography"></div></li>
894
927
  <li>
895
- <h5><span class="tsd-kind-parameter">val</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span></h5>
896
- <div class="tsd-comment tsd-typography"><p>The <code>val</code> parameter represents the value that you want to add to the binary search tree. It
897
- can be of type <code>T</code> (the generic type) or <code>null</code>.</p>
928
+ <h5><span class="tsd-kind-parameter">val</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span></h5>
929
+ <div class="tsd-comment tsd-typography"><p>The <code>val</code> parameter represents the value to be stored in the binary search tree node. It can
930
+ be of type <code>N</code> (the generic type) or <code>null</code>.</p>
898
931
  </div>
899
932
  <div class="tsd-comment tsd-typography"></div></li>
900
933
  <li>
901
- <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">count</span>: <span class="tsd-signature-type">number</span></h5>
902
- <div class="tsd-comment tsd-typography"><p>The <code>count</code> parameter is an optional parameter of type <code>number</code>. It represents the number
903
- of times the value should be added to the binary search tree. If not provided, the default value is <code>undefined</code>.</p>
934
+ <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">count</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> = 1</span></h5>
935
+ <div class="tsd-comment tsd-typography"><p>The <code>count</code> parameter represents the number of times the value should be inserted into
936
+ the binary search tree. By default, it is set to 1, meaning that if no count is specified, the value will be
937
+ inserted once.</p>
904
938
  </div>
905
939
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
906
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The <code>add</code> method is returning a <code>BSTNode&lt;T&gt;</code> object or <code>null</code>.</p>
940
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h4><p>The method <code>add</code> returns a <code>N</code> object or <code>null</code>.</p>
907
941
 
908
942
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
909
- <p>Overrides <a href="BST.html">BST</a>.<a href="BST.html#add">add</a></p>
943
+ <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#add">add</a></p>
910
944
  <ul>
911
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/tree-multiset.ts#L34">src/data-structures/binary-tree/tree-multiset.ts:34</a></li></ul></aside></li></ul></section>
945
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/bst.ts#L49">src/data-structures/binary-tree/bst.ts:49</a></li></ul></aside></li></ul></section>
912
946
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="addMany" class="tsd-anchor"></a>
913
947
  <h3 class="tsd-anchor-link"><span>add<wbr/>Many</span><a href="#addMany" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
914
948
  <ul class="tsd-signatures tsd-is-inherited">
915
- <li class="tsd-signature tsd-anchor-link" id="addMany.addMany-1"><span class="tsd-kind-call-signature">add<wbr/>Many</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">data</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">[]</span><a href="#addMany.addMany-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
949
+ <li class="tsd-signature tsd-anchor-link" id="addMany.addMany-1"><span class="tsd-kind-call-signature">add<wbr/>Many</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">data</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">[]</span><a href="#addMany.addMany-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
916
950
  <li class="tsd-description">
917
951
  <div class="tsd-comment tsd-typography"><p>The <code>addMany</code> function inserts multiple items into a binary tree and returns an array of the inserted nodes or
918
952
  null/undefined values.</p>
@@ -921,21 +955,21 @@ null/undefined values.</p>
921
955
  <h4 class="tsd-parameters-title">Parameters</h4>
922
956
  <ul class="tsd-parameter-list">
923
957
  <li>
924
- <h5><span class="tsd-kind-parameter">data</span>: <span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h5>
925
- <div class="tsd-comment tsd-typography"><p>The <code>data</code> parameter can be either an array of elements of type <code>T</code> or an
926
- array of <code>BinaryTreeNode&lt;T&gt;</code> objects.</p>
958
+ <h5><span class="tsd-kind-parameter">data</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></h5>
959
+ <div class="tsd-comment tsd-typography"><p>The <code>data</code> parameter can be either an array of elements of type <code>N</code> or an
960
+ array of <code>N</code> objects.</p>
927
961
  </div>
928
962
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
929
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-symbol">(</span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>addMany</code> returns an array of <code>BinaryTreeNode&lt;T&gt;</code>, <code>null</code>, or <code>undefined</code> values.</p>
963
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-symbol">(</span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>addMany</code> returns an array of <code>N</code>, <code>null</code>, or <code>undefined</code> values.</p>
930
964
 
931
965
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
932
966
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#addMany">addMany</a></p>
933
967
  <ul>
934
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L380">src/data-structures/binary-tree/binary-tree.ts:380</a></li></ul></aside></li></ul></section>
968
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L362">src/data-structures/binary-tree/abstract-binary-tree.ts:362</a></li></ul></aside></li></ul></section>
935
969
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="addTo" class="tsd-anchor"></a>
936
970
  <h3 class="tsd-anchor-link"><span>add<wbr/>To</span><a href="#addTo" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
937
971
  <ul class="tsd-signatures tsd-is-inherited">
938
- <li class="tsd-signature tsd-anchor-link" id="addTo.addTo-1"><span class="tsd-kind-call-signature">add<wbr/>To</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">newNode</span>, <span class="tsd-kind-parameter">parent</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><a href="#addTo.addTo-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
972
+ <li class="tsd-signature tsd-anchor-link" id="addTo.addTo-1"><span class="tsd-kind-call-signature">add<wbr/>To</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">newNode</span>, <span class="tsd-kind-parameter">parent</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><a href="#addTo.addTo-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
939
973
  <li class="tsd-description">
940
974
  <div class="tsd-comment tsd-typography"><p>The function inserts a new node into a binary tree as the left or right child of a given parent node.</p>
941
975
  </div>
@@ -943,23 +977,23 @@ array of <code>BinaryTreeNode&lt;T&gt;</code> objects.</p>
943
977
  <h4 class="tsd-parameters-title">Parameters</h4>
944
978
  <ul class="tsd-parameter-list">
945
979
  <li>
946
- <h5><span class="tsd-kind-parameter">newNode</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
980
+ <h5><span class="tsd-kind-parameter">newNode</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
947
981
  <div class="tsd-comment tsd-typography"><p>The <code>newNode</code> parameter is an instance of the <code>BinaryTreeNode</code> class or
948
982
  <code>null</code>. It represents the node that needs to be inserted into the binary tree.</p>
949
983
  </div>
950
984
  <div class="tsd-comment tsd-typography"></div></li>
951
985
  <li>
952
- <h5><span class="tsd-kind-parameter">parent</span>: <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
986
+ <h5><span class="tsd-kind-parameter">parent</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
953
987
  <div class="tsd-comment tsd-typography"><p>The <code>parent</code> parameter is a BinaryTreeNode object representing the parent node to which the new node
954
988
  will be inserted as a child.</p>
955
989
  </div>
956
990
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
957
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The method returns the newly inserted node, either as the left child or the right child of the parent node.</p>
991
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h4><p>The method returns the newly inserted node, either as the left child or the right child of the parent node.</p>
958
992
 
959
993
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
960
994
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#addTo">addTo</a></p>
961
995
  <ul>
962
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L340">src/data-structures/binary-tree/binary-tree.ts:340</a></li></ul></aside></li></ul></section>
996
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L322">src/data-structures/binary-tree/abstract-binary-tree.ts:322</a></li></ul></aside></li></ul></section>
963
997
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="allGreaterNodesAdd" class="tsd-anchor"></a>
964
998
  <h3 class="tsd-anchor-link"><span>all<wbr/>Greater<wbr/>Nodes<wbr/>Add</span><a href="#allGreaterNodesAdd" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
965
999
  <ul class="tsd-signatures tsd-is-inherited">
@@ -972,8 +1006,8 @@ that have a greater value than a given node.</p>
972
1006
  <h4 class="tsd-parameters-title">Parameters</h4>
973
1007
  <ul class="tsd-parameter-list">
974
1008
  <li>
975
- <h5><span class="tsd-kind-parameter">node</span>: <a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
976
- <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is of type <code>BSTNode&lt;T&gt;</code>, which represents a node in a binary search tree. It
1009
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1010
+ <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is of type <code>N</code>, which represents a node in a binary search tree. It
977
1011
  contains properties such as <code>id</code> and <code>count</code>.</p>
978
1012
  </div>
979
1013
  <div class="tsd-comment tsd-typography"></div></li>
@@ -995,7 +1029,7 @@ defaults to &#39;id&#39;.</p>
995
1029
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
996
1030
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#allGreaterNodesAdd">allGreaterNodesAdd</a></p>
997
1031
  <ul>
998
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/bst.ts#L345">src/data-structures/binary-tree/bst.ts:345</a></li></ul></aside></li></ul></section>
1032
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/bst.ts#L341">src/data-structures/binary-tree/bst.ts:341</a></li></ul></aside></li></ul></section>
999
1033
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="balance" class="tsd-anchor"></a>
1000
1034
  <h3 class="tsd-anchor-link"><span>balance</span><a href="#balance" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1001
1035
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1009,7 +1043,7 @@ recursive or iterative approach.</p>
1009
1043
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1010
1044
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#balance">balance</a></p>
1011
1045
  <ul>
1012
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/bst.ts#L396">src/data-structures/binary-tree/bst.ts:396</a></li></ul></aside></li></ul></section>
1046
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/bst.ts#L392">src/data-structures/binary-tree/bst.ts:392</a></li></ul></aside></li></ul></section>
1013
1047
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="clear" class="tsd-anchor"></a>
1014
1048
  <h3 class="tsd-anchor-link"><span>clear</span><a href="#clear" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1015
1049
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1021,40 +1055,7 @@ recursive or iterative approach.</p>
1021
1055
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1022
1056
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#clear">clear</a></p>
1023
1057
  <ul>
1024
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L264">src/data-structures/binary-tree/binary-tree.ts:264</a></li></ul></aside></li></ul></section>
1025
- <section class="tsd-panel tsd-member"><a id="createNode" class="tsd-anchor"></a>
1026
- <h3 class="tsd-anchor-link"><span>create<wbr/>Node</span><a href="#createNode" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1027
- <ul class="tsd-signatures">
1028
- <li class="tsd-signature tsd-anchor-link" id="createNode.createNode-1"><span class="tsd-kind-call-signature">create<wbr/>Node</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">id</span>, <span class="tsd-kind-parameter">val</span>, <span class="tsd-kind-parameter">count</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><a href="#createNode.createNode-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1029
- <li class="tsd-description">
1030
- <div class="tsd-comment tsd-typography"><p>The function creates a new BSTNode with the given id, value, and count.</p>
1031
- </div>
1032
- <div class="tsd-parameters">
1033
- <h4 class="tsd-parameters-title">Parameters</h4>
1034
- <ul class="tsd-parameter-list">
1035
- <li>
1036
- <h5><span class="tsd-kind-parameter">id</span>: <span class="tsd-signature-type">number</span></h5>
1037
- <div class="tsd-comment tsd-typography"><p>The id parameter is the unique identifier for the binary tree node. It is used to
1038
- distinguish one node from another in the tree.</p>
1039
- </div>
1040
- <div class="tsd-comment tsd-typography"></div></li>
1041
- <li>
1042
- <h5><span class="tsd-kind-parameter">val</span>: <span class="tsd-signature-type tsd-kind-type-parameter">T</span></h5>
1043
- <div class="tsd-comment tsd-typography"><p>The <code>val</code> parameter represents the value that will be stored in the binary search tree node.</p>
1044
- </div>
1045
- <div class="tsd-comment tsd-typography"></div></li>
1046
- <li>
1047
- <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">count</span>: <span class="tsd-signature-type">number</span></h5>
1048
- <div class="tsd-comment tsd-typography"><p>The &quot;count&quot; parameter is an optional parameter of type number. It represents the number of
1049
- occurrences of the value in the binary search tree node. If not provided, the count will default to 1.</p>
1050
- </div>
1051
- <div class="tsd-comment tsd-typography"></div></li></ul></div>
1052
- <h4 class="tsd-returns-title">Returns <a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4><p>A new instance of the BSTNode class with the specified id, value, and count (if provided).</p>
1053
-
1054
- <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1055
- <p>Overrides <a href="BST.html">BST</a>.<a href="BST.html#createNode">createNode</a></p>
1056
- <ul>
1057
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/tree-multiset.ts#L21">src/data-structures/binary-tree/tree-multiset.ts:21</a></li></ul></aside></li></ul></section>
1058
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L246">src/data-structures/binary-tree/abstract-binary-tree.ts:246</a></li></ul></aside></li></ul></section>
1058
1059
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="fill" class="tsd-anchor"></a>
1059
1060
  <h3 class="tsd-anchor-link"><span>fill</span><a href="#fill" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1060
1061
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1067,9 +1068,9 @@ was successful.</p>
1067
1068
  <h4 class="tsd-parameters-title">Parameters</h4>
1068
1069
  <ul class="tsd-parameter-list">
1069
1070
  <li>
1070
- <h5><span class="tsd-kind-parameter">data</span>: <span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h5>
1071
- <div class="tsd-comment tsd-typography"><p>The <code>data</code> parameter can be either an array of elements of type <code>T</code> or an
1072
- array of <code>BinaryTreeNode&lt;T&gt;</code> objects.</p>
1071
+ <h5><span class="tsd-kind-parameter">data</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></h5>
1072
+ <div class="tsd-comment tsd-typography"><p>The <code>data</code> parameter can be either an array of elements of type <code>N</code> or an
1073
+ array of <code>N</code> objects.</p>
1073
1074
  </div>
1074
1075
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1075
1076
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><p>The method is returning a boolean value.</p>
@@ -1077,11 +1078,11 @@ array of <code>BinaryTreeNode&lt;T&gt;</code> objects.</p>
1077
1078
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1078
1079
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#fill">fill</a></p>
1079
1080
  <ul>
1080
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L427">src/data-structures/binary-tree/binary-tree.ts:427</a></li></ul></aside></li></ul></section>
1081
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L423">src/data-structures/binary-tree/abstract-binary-tree.ts:423</a></li></ul></aside></li></ul></section>
1081
1082
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="get" class="tsd-anchor"></a>
1082
1083
  <h3 class="tsd-anchor-link"><span>get</span><a href="#get" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1083
1084
  <ul class="tsd-signatures tsd-is-inherited">
1084
- <li class="tsd-signature tsd-anchor-link" id="get.get-1"><span class="tsd-kind-call-signature">get</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeProperty</span>, <span class="tsd-kind-parameter">propertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><a href="#get.get-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1085
+ <li class="tsd-signature tsd-anchor-link" id="get.get-1"><span class="tsd-kind-call-signature">get</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeProperty</span>, <span class="tsd-kind-parameter">propertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><a href="#get.get-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1085
1086
  <li class="tsd-description">
1086
1087
  <div class="tsd-comment tsd-typography"><p>The <code>get</code> function returns the first node in a binary search tree that matches the given property value or name.</p>
1087
1088
  </div>
@@ -1089,9 +1090,9 @@ array of <code>BinaryTreeNode&lt;T&gt;</code> objects.</p>
1089
1090
  <h4 class="tsd-parameters-title">Parameters</h4>
1090
1091
  <ul class="tsd-parameter-list">
1091
1092
  <li>
1092
- <h5><span class="tsd-kind-parameter">nodeProperty</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span></h5>
1093
+ <h5><span class="tsd-kind-parameter">nodeProperty</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1093
1094
  <div class="tsd-comment tsd-typography"><p>The <code>nodeProperty</code> parameter can be either a <code>BinaryTreeNodeId</code> or a
1094
- generic type <code>T</code>. It represents the value of the property that you want to search for in the binary search tree.</p>
1095
+ generic type <code>N</code>. It represents the value of the property that you want to search for in the binary search tree.</p>
1095
1096
  </div>
1096
1097
  <div class="tsd-comment tsd-typography"></div></li>
1097
1098
  <li>
@@ -1101,12 +1102,12 @@ specifies the property name to use for searching the binary search tree nodes. I
1101
1102
  <code>&#39;id&#39;</code>.</p>
1102
1103
  </div>
1103
1104
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1104
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The method is returning a BSTNode<T> object or null.</p>
1105
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h4><p>The method is returning a N object or null.</p>
1105
1106
 
1106
1107
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1107
1108
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#get">get</a></p>
1108
1109
  <ul>
1109
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/bst.ts#L127">src/data-structures/binary-tree/bst.ts:127</a></li></ul></aside></li></ul></section>
1110
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/bst.ts#L123">src/data-structures/binary-tree/bst.ts:123</a></li></ul></aside></li></ul></section>
1110
1111
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="getDepth" class="tsd-anchor"></a>
1111
1112
  <h3 class="tsd-anchor-link"><span>get<wbr/>Depth</span><a href="#getDepth" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1112
1113
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1118,8 +1119,8 @@ specifies the property name to use for searching the binary search tree nodes. I
1118
1119
  <h4 class="tsd-parameters-title">Parameters</h4>
1119
1120
  <ul class="tsd-parameter-list">
1120
1121
  <li>
1121
- <h5><span class="tsd-kind-parameter">node</span>: <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1122
- <div class="tsd-comment tsd-typography"><p>BinaryTreeNode<T> - This is the node for which we want to calculate the depth. It is a generic type,
1122
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1123
+ <div class="tsd-comment tsd-typography"><p>N - This is the node for which we want to calculate the depth. It is a generic type,
1123
1124
  meaning it can represent any type of data that we want to store in the node.</p>
1124
1125
  </div>
1125
1126
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
@@ -1128,7 +1129,7 @@ meaning it can represent any type of data that we want to store in the node.</p>
1128
1129
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1129
1130
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#getDepth">getDepth</a></p>
1130
1131
  <ul>
1131
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L485">src/data-structures/binary-tree/binary-tree.ts:485</a></li></ul></aside></li></ul></section>
1132
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L481">src/data-structures/binary-tree/abstract-binary-tree.ts:481</a></li></ul></aside></li></ul></section>
1132
1133
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="getHeight" class="tsd-anchor"></a>
1133
1134
  <h3 class="tsd-anchor-link"><span>get<wbr/>Height</span><a href="#getHeight" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1134
1135
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1141,9 +1142,9 @@ approach.</p>
1141
1142
  <h4 class="tsd-parameters-title">Parameters</h4>
1142
1143
  <ul class="tsd-parameter-list">
1143
1144
  <li>
1144
- <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">beginRoot</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1145
+ <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">beginRoot</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1145
1146
  <div class="tsd-comment tsd-typography"><p>The <code>beginRoot</code> parameter is an optional parameter of type
1146
- <code>BinaryTreeNode&lt;T&gt; | null</code>. It represents the starting node from which to calculate the height of the binary tree.
1147
+ <code>N | null</code>. It represents the starting node from which to calculate the height of the binary tree.
1147
1148
  If no value is provided for <code>beginRoot</code>, the function will use the <code>root</code> property of the class instance as</p>
1148
1149
  </div>
1149
1150
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
@@ -1152,22 +1153,22 @@ If no value is provided for <code>beginRoot</code>, the function will use the <c
1152
1153
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1153
1154
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#getHeight">getHeight</a></p>
1154
1155
  <ul>
1155
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L502">src/data-structures/binary-tree/binary-tree.ts:502</a></li></ul></aside></li></ul></section>
1156
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L498">src/data-structures/binary-tree/abstract-binary-tree.ts:498</a></li></ul></aside></li></ul></section>
1156
1157
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="getLeftMost" class="tsd-anchor"></a>
1157
1158
  <h3 class="tsd-anchor-link"><span>get<wbr/>Left<wbr/>Most</span><a href="#getLeftMost" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1158
1159
  <ul class="tsd-signatures tsd-is-inherited">
1159
- <li class="tsd-signature tsd-anchor-link" id="getLeftMost.getLeftMost-1"><span class="tsd-kind-call-signature">get<wbr/>Left<wbr/>Most</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><a href="#getLeftMost.getLeftMost-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1160
+ <li class="tsd-signature tsd-anchor-link" id="getLeftMost.getLeftMost-1"><span class="tsd-kind-call-signature">get<wbr/>Left<wbr/>Most</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><a href="#getLeftMost.getLeftMost-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1160
1161
  <li class="tsd-description">
1161
1162
  <div class="tsd-comment tsd-typography"><p>The <code>getLeftMost</code> function returns the leftmost node in a binary tree, either recursively or iteratively using tail
1162
1163
  recursion optimization.</p>
1163
1164
  </div>
1164
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The <code>getLeftMost</code> function returns the leftmost node in a binary tree.</p>
1165
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h4><p>The <code>getLeftMost</code> function returns the leftmost node in a binary tree.</p>
1165
1166
 
1166
1167
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1167
1168
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#getLeftMost">getLeftMost</a></p>
1168
1169
  <ul>
1169
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L689">src/data-structures/binary-tree/binary-tree.ts:689</a></li></ul></aside></li>
1170
- <li class="tsd-signature tsd-anchor-link" id="getLeftMost.getLeftMost-2"><span class="tsd-kind-call-signature">get<wbr/>Left<wbr/>Most</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><a href="#getLeftMost.getLeftMost-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1170
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L685">src/data-structures/binary-tree/abstract-binary-tree.ts:685</a></li></ul></aside></li>
1171
+ <li class="tsd-signature tsd-anchor-link" id="getLeftMost.getLeftMost-2"><span class="tsd-kind-call-signature">get<wbr/>Left<wbr/>Most</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><a href="#getLeftMost.getLeftMost-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1171
1172
  <li class="tsd-description">
1172
1173
  <div class="tsd-comment tsd-typography"><p>The <code>getLeftMost</code> function returns the leftmost node in a binary tree, either recursively or iteratively using tail
1173
1174
  recursion optimization.</p>
@@ -1176,17 +1177,17 @@ recursion optimization.</p>
1176
1177
  <h4 class="tsd-parameters-title">Parameters</h4>
1177
1178
  <ul class="tsd-parameter-list">
1178
1179
  <li>
1179
- <h5><span class="tsd-kind-parameter">node</span>: <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1180
- <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is an optional parameter of type <code>BinaryTreeNode&lt;T&gt; | null</code>. It represents the starting node from which to find the leftmost node in a binary tree. If no node is
1180
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1181
+ <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is an optional parameter of type <code>N | null</code>. It represents the starting node from which to find the leftmost node in a binary tree. If no node is
1181
1182
  provided, the function will use the root node of the binary tree.</p>
1182
1183
  </div>
1183
1184
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1184
- <h4 class="tsd-returns-title">Returns <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The <code>getLeftMost</code> function returns the leftmost node in a binary tree.</p>
1185
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h4><p>The <code>getLeftMost</code> function returns the leftmost node in a binary tree.</p>
1185
1186
 
1186
1187
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1187
1188
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#getLeftMost">getLeftMost</a></p>
1188
1189
  <ul>
1189
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L691">src/data-structures/binary-tree/binary-tree.ts:691</a></li></ul></aside></li></ul></section>
1190
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L687">src/data-structures/binary-tree/abstract-binary-tree.ts:687</a></li></ul></aside></li></ul></section>
1190
1191
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="getMinHeight" class="tsd-anchor"></a>
1191
1192
  <h3 class="tsd-anchor-link"><span>get<wbr/>Min<wbr/>Height</span><a href="#getMinHeight" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1192
1193
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1199,9 +1200,9 @@ approach.</p>
1199
1200
  <h4 class="tsd-parameters-title">Parameters</h4>
1200
1201
  <ul class="tsd-parameter-list">
1201
1202
  <li>
1202
- <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">beginRoot</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1203
+ <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">beginRoot</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1203
1204
  <div class="tsd-comment tsd-typography"><p>The <code>beginRoot</code> parameter is an optional parameter of type
1204
- <code>BinaryTreeNode&lt;T&gt; | null</code>. It represents the starting node from which to calculate the minimum height of the binary
1205
+ <code>N | null</code>. It represents the starting node from which to calculate the minimum height of the binary
1205
1206
  tree. If no value is provided for <code>beginRoot</code>, the function will use the root node of the binary tree.</p>
1206
1207
  </div>
1207
1208
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
@@ -1210,11 +1211,11 @@ tree. If no value is provided for <code>beginRoot</code>, the function will use
1210
1211
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1211
1212
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#getMinHeight">getMinHeight</a></p>
1212
1213
  <ul>
1213
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L551">src/data-structures/binary-tree/binary-tree.ts:551</a></li></ul></aside></li></ul></section>
1214
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L547">src/data-structures/binary-tree/abstract-binary-tree.ts:547</a></li></ul></aside></li></ul></section>
1214
1215
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="getNodes" class="tsd-anchor"></a>
1215
1216
  <h3 class="tsd-anchor-link"><span>get<wbr/>Nodes</span><a href="#getNodes" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1216
1217
  <ul class="tsd-signatures tsd-is-inherited">
1217
- <li class="tsd-signature tsd-anchor-link" id="getNodes.getNodes-1"><span class="tsd-kind-call-signature">get<wbr/>Nodes</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeProperty</span>, <span class="tsd-kind-parameter">propertyName</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">onlyOne</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span><a href="#getNodes.getNodes-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1218
+ <li class="tsd-signature tsd-anchor-link" id="getNodes.getNodes-1"><span class="tsd-kind-call-signature">get<wbr/>Nodes</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">nodeProperty</span>, <span class="tsd-kind-parameter">propertyName</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">onlyOne</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><a href="#getNodes.getNodes-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1218
1219
  <li class="tsd-description">
1219
1220
  <div class="tsd-comment tsd-typography"><p>The function <code>getNodes</code> returns an array of binary search tree nodes that match a given property value, with the
1220
1221
  option to specify the property name and whether to return only one node.</p>
@@ -1223,9 +1224,9 @@ option to specify the property name and whether to return only one node.</p>
1223
1224
  <h4 class="tsd-parameters-title">Parameters</h4>
1224
1225
  <ul class="tsd-parameter-list">
1225
1226
  <li>
1226
- <h5><span class="tsd-kind-parameter">nodeProperty</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span></h5>
1227
+ <h5><span class="tsd-kind-parameter">nodeProperty</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1227
1228
  <div class="tsd-comment tsd-typography"><p>The <code>nodeProperty</code> parameter can be either a <code>BinaryTreeNodeId</code> or a
1228
- generic type <code>T</code>. It represents the property value that you want to search for in the binary search tree.</p>
1229
+ generic type <code>N</code>. It represents the property value that you want to search for in the binary search tree.</p>
1229
1230
  </div>
1230
1231
  <div class="tsd-comment tsd-typography"></div></li>
1231
1232
  <li>
@@ -1242,16 +1243,16 @@ nodeProperty. If set to true, the function will stop traversing the tree and ret
1242
1243
  to false or not provided, the function will return all nodes that match the given nodeProperty.</p>
1243
1244
  </div>
1244
1245
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1245
- <h4 class="tsd-returns-title">Returns <a href="BSTNode.html" class="tsd-signature-type tsd-kind-class">BSTNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h4><p>an array of BSTNode<T> objects.</p>
1246
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h4><p>an array of N objects.</p>
1246
1247
 
1247
1248
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1248
1249
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#getNodes">getNodes</a></p>
1249
1250
  <ul>
1250
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/bst.ts#L217">src/data-structures/binary-tree/bst.ts:217</a></li></ul></aside></li></ul></section>
1251
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/bst.ts#L213">src/data-structures/binary-tree/bst.ts:213</a></li></ul></aside></li></ul></section>
1251
1252
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="getPathToRoot" class="tsd-anchor"></a>
1252
1253
  <h3 class="tsd-anchor-link"><span>get<wbr/>Path<wbr/>To<wbr/>Root</span><a href="#getPathToRoot" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1253
1254
  <ul class="tsd-signatures tsd-is-inherited">
1254
- <li class="tsd-signature tsd-anchor-link" id="getPathToRoot.getPathToRoot-1"><span class="tsd-kind-call-signature">get<wbr/>Path<wbr/>To<wbr/>Root</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span><a href="#getPathToRoot.getPathToRoot-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1255
+ <li class="tsd-signature tsd-anchor-link" id="getPathToRoot.getPathToRoot-1"><span class="tsd-kind-call-signature">get<wbr/>Path<wbr/>To<wbr/>Root</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><a href="#getPathToRoot.getPathToRoot-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1255
1256
  <li class="tsd-description">
1256
1257
  <div class="tsd-comment tsd-typography"><p>The function getPathToRoot returns an array of BinaryTreeNode objects representing the path from a given node to the
1257
1258
  root of a binary tree.</p>
@@ -1260,21 +1261,21 @@ root of a binary tree.</p>
1260
1261
  <h4 class="tsd-parameters-title">Parameters</h4>
1261
1262
  <ul class="tsd-parameter-list">
1262
1263
  <li>
1263
- <h5><span class="tsd-kind-parameter">node</span>: <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1264
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1264
1265
  <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is a BinaryTreeNode object.</p>
1265
1266
  </div>
1266
1267
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1267
- <h4 class="tsd-returns-title">Returns <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>getPathToRoot</code> returns an array of <code>BinaryTreeNode&lt;T&gt;</code> objects, representing the path from
1268
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>getPathToRoot</code> returns an array of <code>N</code> objects, representing the path from
1268
1269
  the given <code>node</code> to the root of the binary tree.</p>
1269
1270
 
1270
1271
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1271
1272
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#getPathToRoot">getPathToRoot</a></p>
1272
1273
  <ul>
1273
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L679">src/data-structures/binary-tree/binary-tree.ts:679</a></li></ul></aside></li></ul></section>
1274
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L675">src/data-structures/binary-tree/abstract-binary-tree.ts:675</a></li></ul></aside></li></ul></section>
1274
1275
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="getPredecessor" class="tsd-anchor"></a>
1275
1276
  <h3 class="tsd-anchor-link"><span>get<wbr/>Predecessor</span><a href="#getPredecessor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1276
1277
  <ul class="tsd-signatures tsd-is-inherited">
1277
- <li class="tsd-signature tsd-anchor-link" id="getPredecessor.getPredecessor-1"><span class="tsd-kind-call-signature">get<wbr/>Predecessor</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><a href="#getPredecessor.getPredecessor-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1278
+ <li class="tsd-signature tsd-anchor-link" id="getPredecessor.getPredecessor-1"><span class="tsd-kind-call-signature">get<wbr/>Predecessor</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><a href="#getPredecessor.getPredecessor-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1278
1279
  <li class="tsd-description">
1279
1280
  <div class="tsd-comment tsd-typography"><p>The function returns the predecessor of a given node in a binary tree.</p>
1280
1281
  </div>
@@ -1282,31 +1283,31 @@ the given <code>node</code> to the root of the binary tree.</p>
1282
1283
  <h4 class="tsd-parameters-title">Parameters</h4>
1283
1284
  <ul class="tsd-parameter-list">
1284
1285
  <li>
1285
- <h5><span class="tsd-kind-parameter">node</span>: <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1286
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1286
1287
  <div class="tsd-comment tsd-typography"><p>The parameter <code>node</code> is a BinaryTreeNode object, representing a node in a binary tree.</p>
1287
1288
  </div>
1288
1289
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1289
- <h4 class="tsd-returns-title">Returns <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4><p>the predecessor of the given node in a binary tree.</p>
1290
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h4><p>the predecessor of the given node in a binary tree.</p>
1290
1291
 
1291
1292
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1292
1293
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#getPredecessor">getPredecessor</a></p>
1293
1294
  <ul>
1294
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1209">src/data-structures/binary-tree/binary-tree.ts:1209</a></li></ul></aside></li></ul></section>
1295
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1205">src/data-structures/binary-tree/abstract-binary-tree.ts:1205</a></li></ul></aside></li></ul></section>
1295
1296
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="getRightMost" class="tsd-anchor"></a>
1296
1297
  <h3 class="tsd-anchor-link"><span>get<wbr/>Right<wbr/>Most</span><a href="#getRightMost" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1297
1298
  <ul class="tsd-signatures tsd-is-inherited">
1298
- <li class="tsd-signature tsd-anchor-link" id="getRightMost.getRightMost-1"><span class="tsd-kind-call-signature">get<wbr/>Right<wbr/>Most</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><a href="#getRightMost.getRightMost-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1299
+ <li class="tsd-signature tsd-anchor-link" id="getRightMost.getRightMost-1"><span class="tsd-kind-call-signature">get<wbr/>Right<wbr/>Most</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><a href="#getRightMost.getRightMost-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1299
1300
  <li class="tsd-description">
1300
1301
  <div class="tsd-comment tsd-typography"><p>The <code>getRightMost</code> function returns the rightmost node in a binary tree, either recursively or iteratively using
1301
1302
  tail recursion optimization.</p>
1302
1303
  </div>
1303
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The <code>getRightMost</code> function returns the rightmost node in a binary tree.</p>
1304
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h4><p>The <code>getRightMost</code> function returns the rightmost node in a binary tree.</p>
1304
1305
 
1305
1306
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1306
1307
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#getRightMost">getRightMost</a></p>
1307
1308
  <ul>
1308
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L724">src/data-structures/binary-tree/binary-tree.ts:724</a></li></ul></aside></li>
1309
- <li class="tsd-signature tsd-anchor-link" id="getRightMost.getRightMost-2"><span class="tsd-kind-call-signature">get<wbr/>Right<wbr/>Most</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><a href="#getRightMost.getRightMost-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1309
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L720">src/data-structures/binary-tree/abstract-binary-tree.ts:720</a></li></ul></aside></li>
1310
+ <li class="tsd-signature tsd-anchor-link" id="getRightMost.getRightMost-2"><span class="tsd-kind-call-signature">get<wbr/>Right<wbr/>Most</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><a href="#getRightMost.getRightMost-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1310
1311
  <li class="tsd-description">
1311
1312
  <div class="tsd-comment tsd-typography"><p>The <code>getRightMost</code> function returns the rightmost node in a binary tree, either recursively or iteratively using
1312
1313
  tail recursion optimization.</p>
@@ -1315,17 +1316,17 @@ tail recursion optimization.</p>
1315
1316
  <h4 class="tsd-parameters-title">Parameters</h4>
1316
1317
  <ul class="tsd-parameter-list">
1317
1318
  <li>
1318
- <h5><span class="tsd-kind-parameter">node</span>: <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1319
- <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is an optional parameter of type <code>BinaryTreeNode&lt;T&gt; | null</code>. It represents the starting node from which to find the rightmost node in a binary tree. If no node is
1319
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1320
+ <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is an optional parameter of type <code>N | null</code>. It represents the starting node from which to find the rightmost node in a binary tree. If no node is
1320
1321
  provided, the function will use the root node of the binary tree.</p>
1321
1322
  </div>
1322
1323
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1323
- <h4 class="tsd-returns-title">Returns <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The <code>getRightMost</code> function returns the rightmost node in a binary tree.</p>
1324
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h4><p>The <code>getRightMost</code> function returns the rightmost node in a binary tree.</p>
1324
1325
 
1325
1326
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1326
1327
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#getRightMost">getRightMost</a></p>
1327
1328
  <ul>
1328
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L726">src/data-structures/binary-tree/binary-tree.ts:726</a></li></ul></aside></li></ul></section>
1329
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L722">src/data-structures/binary-tree/abstract-binary-tree.ts:722</a></li></ul></aside></li></ul></section>
1329
1330
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="getSubTreeSizeAndCount" class="tsd-anchor"></a>
1330
1331
  <h3 class="tsd-anchor-link"><span>get<wbr/>Sub<wbr/>Tree<wbr/>Size<wbr/>And<wbr/>Count</span><a href="#getSubTreeSizeAndCount" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1331
1332
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1338,7 +1339,7 @@ traversal.</p>
1338
1339
  <h4 class="tsd-parameters-title">Parameters</h4>
1339
1340
  <ul class="tsd-parameter-list">
1340
1341
  <li>
1341
- <h5><span class="tsd-kind-parameter">subTreeRoot</span>: <span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1342
+ <h5><span class="tsd-kind-parameter">subTreeRoot</span>: <span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1342
1343
  <div class="tsd-comment tsd-typography"><p>The <code>subTreeRoot</code> parameter is the root node of a binary
1343
1344
  tree.</p>
1344
1345
  </div>
@@ -1349,7 +1350,7 @@ represents the size of the subtree, and the second element represents the count
1349
1350
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1350
1351
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#getSubTreeSizeAndCount">getSubTreeSizeAndCount</a></p>
1351
1352
  <ul>
1352
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L803">src/data-structures/binary-tree/binary-tree.ts:803</a></li></ul></aside></li></ul></section>
1353
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L799">src/data-structures/binary-tree/abstract-binary-tree.ts:799</a></li></ul></aside></li></ul></section>
1353
1354
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="has" class="tsd-anchor"></a>
1354
1355
  <h3 class="tsd-anchor-link"><span>has</span><a href="#has" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1355
1356
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1362,9 +1363,9 @@ property.</p>
1362
1363
  <h4 class="tsd-parameters-title">Parameters</h4>
1363
1364
  <ul class="tsd-parameter-list">
1364
1365
  <li>
1365
- <h5><span class="tsd-kind-parameter">nodeProperty</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span></h5>
1366
+ <h5><span class="tsd-kind-parameter">nodeProperty</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1366
1367
  <div class="tsd-comment tsd-typography"><p>The <code>nodeProperty</code> parameter can be either a <code>BinaryTreeNodeId</code> or a
1367
- generic type <code>T</code>. It represents the property of a binary tree node that you want to check.</p>
1368
+ generic type <code>N</code>. It represents the property of a binary tree node that you want to check.</p>
1368
1369
  </div>
1369
1370
  <div class="tsd-comment tsd-typography"></div></li>
1370
1371
  <li>
@@ -1378,7 +1379,7 @@ specifies the name of the property to check for in the nodes.</p>
1378
1379
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1379
1380
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#has">has</a></p>
1380
1381
  <ul>
1381
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L654">src/data-structures/binary-tree/binary-tree.ts:654</a></li></ul></aside></li></ul></section>
1382
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L650">src/data-structures/binary-tree/abstract-binary-tree.ts:650</a></li></ul></aside></li></ul></section>
1382
1383
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="isAVLBalanced" class="tsd-anchor"></a>
1383
1384
  <h3 class="tsd-anchor-link"><span>isAVLBalanced</span><a href="#isAVLBalanced" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1384
1385
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1392,7 +1393,7 @@ is balanced according to the AVL tree property, and <code>false</code> otherwise
1392
1393
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1393
1394
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#isAVLBalanced">isAVLBalanced</a></p>
1394
1395
  <ul>
1395
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/bst.ts#L437">src/data-structures/binary-tree/bst.ts:437</a></li></ul></aside></li></ul></section>
1396
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/bst.ts#L433">src/data-structures/binary-tree/bst.ts:433</a></li></ul></aside></li></ul></section>
1396
1397
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="isBST" class="tsd-anchor"></a>
1397
1398
  <h3 class="tsd-anchor-link"><span>isBST</span><a href="#isBST" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1398
1399
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1404,8 +1405,8 @@ is balanced according to the AVL tree property, and <code>false</code> otherwise
1404
1405
  <h4 class="tsd-parameters-title">Parameters</h4>
1405
1406
  <ul class="tsd-parameter-list">
1406
1407
  <li>
1407
- <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1408
- <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is an optional parameter of type <code>BinaryTreeNode&lt;T&gt; | null</code>. It represents the root node of the binary search tree (BST) that we want to check for validity. If no node
1408
+ <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1409
+ <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is an optional parameter of type <code>N | null</code>. It represents the root node of the binary search tree (BST) that we want to check for validity. If no node
1409
1410
  is provided, the function will default to using the root node of the BST instance that</p>
1410
1411
  </div>
1411
1412
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
@@ -1415,7 +1416,7 @@ tree, and <code>false</code> otherwise.</p>
1415
1416
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1416
1417
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#isBST">isBST</a></p>
1417
1418
  <ul>
1418
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L766">src/data-structures/binary-tree/binary-tree.ts:766</a></li></ul></aside></li></ul></section>
1419
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L762">src/data-structures/binary-tree/abstract-binary-tree.ts:762</a></li></ul></aside></li></ul></section>
1419
1420
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="isBalanced" class="tsd-anchor"></a>
1420
1421
  <h3 class="tsd-anchor-link"><span>is<wbr/>Balanced</span><a href="#isBalanced" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1421
1422
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1427,9 +1428,9 @@ tree, and <code>false</code> otherwise.</p>
1427
1428
  <h4 class="tsd-parameters-title">Parameters</h4>
1428
1429
  <ul class="tsd-parameter-list">
1429
1430
  <li>
1430
- <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">beginRoot</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1431
+ <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">beginRoot</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1431
1432
  <div class="tsd-comment tsd-typography"><p>The <code>beginRoot</code> parameter is the root node of a binary tree. It is
1432
- of type <code>BinaryTreeNode&lt;T&gt; | null</code>, which means it can either be a <code>BinaryTreeNode</code> object or <code>null</code>.</p>
1433
+ of type <code>N | null</code>, which means it can either be a <code>BinaryTreeNode</code> object or <code>null</code>.</p>
1433
1434
  </div>
1434
1435
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1435
1436
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><p>The method is returning a boolean value.</p>
@@ -1437,7 +1438,7 @@ of type <code>BinaryTreeNode&lt;T&gt; | null</code>, which means it can either b
1437
1438
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1438
1439
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#isBalanced">isBalanced</a></p>
1439
1440
  <ul>
1440
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L599">src/data-structures/binary-tree/binary-tree.ts:599</a></li></ul></aside></li></ul></section>
1441
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L595">src/data-structures/binary-tree/abstract-binary-tree.ts:595</a></li></ul></aside></li></ul></section>
1441
1442
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="isEmpty" class="tsd-anchor"></a>
1442
1443
  <h3 class="tsd-anchor-link"><span>is<wbr/>Empty</span><a href="#isEmpty" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1443
1444
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1450,7 +1451,7 @@ of type <code>BinaryTreeNode&lt;T&gt; | null</code>, which means it can either b
1450
1451
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1451
1452
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#isEmpty">isEmpty</a></p>
1452
1453
  <ul>
1453
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L275">src/data-structures/binary-tree/binary-tree.ts:275</a></li></ul></aside></li></ul></section>
1454
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L257">src/data-structures/binary-tree/abstract-binary-tree.ts:257</a></li></ul></aside></li></ul></section>
1454
1455
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="lastKey" class="tsd-anchor"></a>
1455
1456
  <h3 class="tsd-anchor-link"><span>last<wbr/>Key</span><a href="#lastKey" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1456
1457
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1467,7 +1468,7 @@ there are no nodes in</p>
1467
1468
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1468
1469
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#lastKey">lastKey</a></p>
1469
1470
  <ul>
1470
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/bst.ts#L140">src/data-structures/binary-tree/bst.ts:140</a></li></ul></aside></li></ul></section>
1471
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/bst.ts#L136">src/data-structures/binary-tree/bst.ts:136</a></li></ul></aside></li></ul></section>
1471
1472
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="lesserSum" class="tsd-anchor"></a>
1472
1473
  <h3 class="tsd-anchor-link"><span>lesser<wbr/>Sum</span><a href="#lesserSum" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1473
1474
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1497,7 +1498,7 @@ binary search tree that have a property value lesser than the given <code>id</co
1497
1498
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1498
1499
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#lesserSum">lesserSum</a></p>
1499
1500
  <ul>
1500
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/bst.ts#L268">src/data-structures/binary-tree/bst.ts:268</a></li></ul></aside></li></ul></section>
1501
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/bst.ts#L264">src/data-structures/binary-tree/bst.ts:264</a></li></ul></aside></li></ul></section>
1501
1502
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="levelIterative" class="tsd-anchor"></a>
1502
1503
  <h3 class="tsd-anchor-link"><span>level<wbr/>Iterative</span><a href="#levelIterative" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1503
1504
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1510,18 +1511,18 @@ in an array, based on a specified property name.</p>
1510
1511
  <h4 class="tsd-parameters-title">Parameters</h4>
1511
1512
  <ul class="tsd-parameter-list">
1512
1513
  <li>
1513
- <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1514
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1514
1515
  <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is a BinaryTreeNode object representing the starting
1515
1516
  node for the level order traversal. It can be null if no specific node is provided, in which case the root node of
1516
1517
  the tree is used as the starting node.</p>
1517
1518
  </div>
1518
1519
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1519
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>levelIterative</code> returns an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
1520
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>levelIterative</code> returns an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
1520
1521
 
1521
1522
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1522
1523
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#levelIterative">levelIterative</a></p>
1523
1524
  <ul>
1524
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1086">src/data-structures/binary-tree/binary-tree.ts:1086</a></li></ul></aside></li>
1525
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1082">src/data-structures/binary-tree/abstract-binary-tree.ts:1082</a></li></ul></aside></li>
1525
1526
  <li class="tsd-signature tsd-anchor-link" id="levelIterative.levelIterative-2"><span class="tsd-kind-call-signature">level<wbr/>Iterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><a href="#levelIterative.levelIterative-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1526
1527
  <li class="tsd-description">
1527
1528
  <div class="tsd-comment tsd-typography"><p>The <code>levelIterative</code> function performs a level-order traversal on a binary tree and returns the values of the nodes
@@ -1531,7 +1532,7 @@ in an array, based on a specified property name.</p>
1531
1532
  <h4 class="tsd-parameters-title">Parameters</h4>
1532
1533
  <ul class="tsd-parameter-list">
1533
1534
  <li>
1534
- <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1535
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1535
1536
  <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is a BinaryTreeNode object representing the starting
1536
1537
  node for the level order traversal. It can be null if no specific node is provided, in which case the root node of
1537
1538
  the tree is used as the starting node.</p>
@@ -1545,13 +1546,13 @@ will accumulate results based on that property. If no property name is provided,
1545
1546
  accumulating results</p>
1546
1547
  </div>
1547
1548
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1548
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>levelIterative</code> returns an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
1549
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>levelIterative</code> returns an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
1549
1550
 
1550
1551
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1551
1552
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#levelIterative">levelIterative</a></p>
1552
1553
  <ul>
1553
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1088">src/data-structures/binary-tree/binary-tree.ts:1088</a></li></ul></aside></li>
1554
- <li class="tsd-signature tsd-anchor-link" id="levelIterative.levelIterative-3"><span class="tsd-kind-call-signature">level<wbr/>Iterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span><a href="#levelIterative.levelIterative-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1554
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1084">src/data-structures/binary-tree/abstract-binary-tree.ts:1084</a></li></ul></aside></li>
1555
+ <li class="tsd-signature tsd-anchor-link" id="levelIterative.levelIterative-3"><span class="tsd-kind-call-signature">level<wbr/>Iterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><a href="#levelIterative.levelIterative-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1555
1556
  <li class="tsd-description">
1556
1557
  <div class="tsd-comment tsd-typography"><p>The <code>levelIterative</code> function performs a level-order traversal on a binary tree and returns the values of the nodes
1557
1558
  in an array, based on a specified property name.</p>
@@ -1560,7 +1561,7 @@ in an array, based on a specified property name.</p>
1560
1561
  <h4 class="tsd-parameters-title">Parameters</h4>
1561
1562
  <ul class="tsd-parameter-list">
1562
1563
  <li>
1563
- <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1564
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1564
1565
  <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is a BinaryTreeNode object representing the starting
1565
1566
  node for the level order traversal. It can be null if no specific node is provided, in which case the root node of
1566
1567
  the tree is used as the starting node.</p>
@@ -1574,13 +1575,13 @@ will accumulate results based on that property. If no property name is provided,
1574
1575
  accumulating results</p>
1575
1576
  </div>
1576
1577
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1577
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>levelIterative</code> returns an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
1578
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>levelIterative</code> returns an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
1578
1579
 
1579
1580
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1580
1581
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#levelIterative">levelIterative</a></p>
1581
1582
  <ul>
1582
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1090">src/data-structures/binary-tree/binary-tree.ts:1090</a></li></ul></aside></li>
1583
- <li class="tsd-signature tsd-anchor-link" id="levelIterative.levelIterative-4"><span class="tsd-kind-call-signature">level<wbr/>Iterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span><a href="#levelIterative.levelIterative-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1583
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1086">src/data-structures/binary-tree/abstract-binary-tree.ts:1086</a></li></ul></aside></li>
1584
+ <li class="tsd-signature tsd-anchor-link" id="levelIterative.levelIterative-4"><span class="tsd-kind-call-signature">level<wbr/>Iterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><a href="#levelIterative.levelIterative-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1584
1585
  <li class="tsd-description">
1585
1586
  <div class="tsd-comment tsd-typography"><p>The <code>levelIterative</code> function performs a level-order traversal on a binary tree and returns the values of the nodes
1586
1587
  in an array, based on a specified property name.</p>
@@ -1589,7 +1590,7 @@ in an array, based on a specified property name.</p>
1589
1590
  <h4 class="tsd-parameters-title">Parameters</h4>
1590
1591
  <ul class="tsd-parameter-list">
1591
1592
  <li>
1592
- <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1593
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1593
1594
  <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is a BinaryTreeNode object representing the starting
1594
1595
  node for the level order traversal. It can be null if no specific node is provided, in which case the root node of
1595
1596
  the tree is used as the starting node.</p>
@@ -1603,12 +1604,12 @@ will accumulate results based on that property. If no property name is provided,
1603
1604
  accumulating results</p>
1604
1605
  </div>
1605
1606
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1606
- <h4 class="tsd-returns-title">Returns <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>levelIterative</code> returns an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
1607
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>levelIterative</code> returns an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
1607
1608
 
1608
1609
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1609
1610
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#levelIterative">levelIterative</a></p>
1610
1611
  <ul>
1611
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1092">src/data-structures/binary-tree/binary-tree.ts:1092</a></li></ul></aside></li>
1612
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1088">src/data-structures/binary-tree/abstract-binary-tree.ts:1088</a></li></ul></aside></li>
1612
1613
  <li class="tsd-signature tsd-anchor-link" id="levelIterative.levelIterative-5"><span class="tsd-kind-call-signature">level<wbr/>Iterative</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><a href="#levelIterative.levelIterative-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1613
1614
  <li class="tsd-description">
1614
1615
  <div class="tsd-comment tsd-typography"><p>The <code>levelIterative</code> function performs a level-order traversal on a binary tree and returns the values of the nodes
@@ -1618,7 +1619,7 @@ in an array, based on a specified property name.</p>
1618
1619
  <h4 class="tsd-parameters-title">Parameters</h4>
1619
1620
  <ul class="tsd-parameter-list">
1620
1621
  <li>
1621
- <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1622
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1622
1623
  <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is a BinaryTreeNode object representing the starting
1623
1624
  node for the level order traversal. It can be null if no specific node is provided, in which case the root node of
1624
1625
  the tree is used as the starting node.</p>
@@ -1632,12 +1633,12 @@ will accumulate results based on that property. If no property name is provided,
1632
1633
  accumulating results</p>
1633
1634
  </div>
1634
1635
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1635
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>levelIterative</code> returns an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
1636
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>levelIterative</code> returns an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
1636
1637
 
1637
1638
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1638
1639
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#levelIterative">levelIterative</a></p>
1639
1640
  <ul>
1640
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1094">src/data-structures/binary-tree/binary-tree.ts:1094</a></li></ul></aside></li></ul></section>
1641
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1090">src/data-structures/binary-tree/abstract-binary-tree.ts:1090</a></li></ul></aside></li></ul></section>
1641
1642
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="listLevels" class="tsd-anchor"></a>
1642
1643
  <h3 class="tsd-anchor-link"><span>list<wbr/>Levels</span><a href="#listLevels" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1643
1644
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1649,17 +1650,17 @@ accumulating results</p>
1649
1650
  <h4 class="tsd-parameters-title">Parameters</h4>
1650
1651
  <ul class="tsd-parameter-list">
1651
1652
  <li>
1652
- <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1653
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1653
1654
  <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is a BinaryTreeNode object or null. It represents the
1654
1655
  root node of a binary tree. If it is null, the function will use the root node of the current binary tree instance.</p>
1655
1656
  </div>
1656
1657
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1657
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>listLevels</code> returns a 2D array of <code>ResultByProperty&lt;T&gt;</code> objects.</p>
1658
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>listLevels</code> returns a 2D array of <code>AbstractResultByProperty&lt;N&gt;</code> objects.</p>
1658
1659
 
1659
1660
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1660
1661
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#listLevels">listLevels</a></p>
1661
1662
  <ul>
1662
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1132">src/data-structures/binary-tree/binary-tree.ts:1132</a></li></ul></aside></li>
1663
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1128">src/data-structures/binary-tree/abstract-binary-tree.ts:1128</a></li></ul></aside></li>
1663
1664
  <li class="tsd-signature tsd-anchor-link" id="listLevels.listLevels-2"><span class="tsd-kind-call-signature">list<wbr/>Levels</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><a href="#listLevels.listLevels-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1664
1665
  <li class="tsd-description">
1665
1666
  <div class="tsd-comment tsd-typography"><p>The <code>listLevels</code> function collects nodes from a binary tree by a specified property and organizes them into levels.</p>
@@ -1668,7 +1669,7 @@ root node of a binary tree. If it is null, the function will use the root node o
1668
1669
  <h4 class="tsd-parameters-title">Parameters</h4>
1669
1670
  <ul class="tsd-parameter-list">
1670
1671
  <li>
1671
- <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1672
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1672
1673
  <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is a BinaryTreeNode object or null. It represents the
1673
1674
  root node of a binary tree. If it is null, the function will use the root node of the current binary tree instance.</p>
1674
1675
  </div>
@@ -1680,13 +1681,13 @@ specifies the property of the <code>BinaryTreeNode</code> object to collect at e
1680
1681
  values:</p>
1681
1682
  </div>
1682
1683
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1683
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>listLevels</code> returns a 2D array of <code>ResultByProperty&lt;T&gt;</code> objects.</p>
1684
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>listLevels</code> returns a 2D array of <code>AbstractResultByProperty&lt;N&gt;</code> objects.</p>
1684
1685
 
1685
1686
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1686
1687
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#listLevels">listLevels</a></p>
1687
1688
  <ul>
1688
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1134">src/data-structures/binary-tree/binary-tree.ts:1134</a></li></ul></aside></li>
1689
- <li class="tsd-signature tsd-anchor-link" id="listLevels.listLevels-3"><span class="tsd-kind-call-signature">list<wbr/>Levels</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><a href="#listLevels.listLevels-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1689
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1130">src/data-structures/binary-tree/abstract-binary-tree.ts:1130</a></li></ul></aside></li>
1690
+ <li class="tsd-signature tsd-anchor-link" id="listLevels.listLevels-3"><span class="tsd-kind-call-signature">list<wbr/>Levels</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><a href="#listLevels.listLevels-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1690
1691
  <li class="tsd-description">
1691
1692
  <div class="tsd-comment tsd-typography"><p>The <code>listLevels</code> function collects nodes from a binary tree by a specified property and organizes them into levels.</p>
1692
1693
  </div>
@@ -1694,7 +1695,7 @@ values:</p>
1694
1695
  <h4 class="tsd-parameters-title">Parameters</h4>
1695
1696
  <ul class="tsd-parameter-list">
1696
1697
  <li>
1697
- <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1698
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1698
1699
  <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is a BinaryTreeNode object or null. It represents the
1699
1700
  root node of a binary tree. If it is null, the function will use the root node of the current binary tree instance.</p>
1700
1701
  </div>
@@ -1706,13 +1707,13 @@ specifies the property of the <code>BinaryTreeNode</code> object to collect at e
1706
1707
  values:</p>
1707
1708
  </div>
1708
1709
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1709
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>listLevels</code> returns a 2D array of <code>ResultByProperty&lt;T&gt;</code> objects.</p>
1710
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">&quot;val&quot;</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>listLevels</code> returns a 2D array of <code>AbstractResultByProperty&lt;N&gt;</code> objects.</p>
1710
1711
 
1711
1712
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1712
1713
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#listLevels">listLevels</a></p>
1713
1714
  <ul>
1714
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1136">src/data-structures/binary-tree/binary-tree.ts:1136</a></li></ul></aside></li>
1715
- <li class="tsd-signature tsd-anchor-link" id="listLevels.listLevels-4"><span class="tsd-kind-call-signature">list<wbr/>Levels</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><a href="#listLevels.listLevels-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1715
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1132">src/data-structures/binary-tree/abstract-binary-tree.ts:1132</a></li></ul></aside></li>
1716
+ <li class="tsd-signature tsd-anchor-link" id="listLevels.listLevels-4"><span class="tsd-kind-call-signature">list<wbr/>Levels</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><a href="#listLevels.listLevels-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1716
1717
  <li class="tsd-description">
1717
1718
  <div class="tsd-comment tsd-typography"><p>The <code>listLevels</code> function collects nodes from a binary tree by a specified property and organizes them into levels.</p>
1718
1719
  </div>
@@ -1720,7 +1721,7 @@ values:</p>
1720
1721
  <h4 class="tsd-parameters-title">Parameters</h4>
1721
1722
  <ul class="tsd-parameter-list">
1722
1723
  <li>
1723
- <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1724
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1724
1725
  <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is a BinaryTreeNode object or null. It represents the
1725
1726
  root node of a binary tree. If it is null, the function will use the root node of the current binary tree instance.</p>
1726
1727
  </div>
@@ -1732,12 +1733,12 @@ specifies the property of the <code>BinaryTreeNode</code> object to collect at e
1732
1733
  values:</p>
1733
1734
  </div>
1734
1735
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1735
- <h4 class="tsd-returns-title">Returns <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>listLevels</code> returns a 2D array of <code>ResultByProperty&lt;T&gt;</code> objects.</p>
1736
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>listLevels</code> returns a 2D array of <code>AbstractResultByProperty&lt;N&gt;</code> objects.</p>
1736
1737
 
1737
1738
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1738
1739
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#listLevels">listLevels</a></p>
1739
1740
  <ul>
1740
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1138">src/data-structures/binary-tree/binary-tree.ts:1138</a></li></ul></aside></li>
1741
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1134">src/data-structures/binary-tree/abstract-binary-tree.ts:1134</a></li></ul></aside></li>
1741
1742
  <li class="tsd-signature tsd-anchor-link" id="listLevels.listLevels-5"><span class="tsd-kind-call-signature">list<wbr/>Levels</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">node</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span><a href="#listLevels.listLevels-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1742
1743
  <li class="tsd-description">
1743
1744
  <div class="tsd-comment tsd-typography"><p>The <code>listLevels</code> function collects nodes from a binary tree by a specified property and organizes them into levels.</p>
@@ -1746,7 +1747,7 @@ values:</p>
1746
1747
  <h4 class="tsd-parameters-title">Parameters</h4>
1747
1748
  <ul class="tsd-parameter-list">
1748
1749
  <li>
1749
- <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1750
+ <h5><span class="tsd-kind-parameter">node</span>: <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1750
1751
  <div class="tsd-comment tsd-typography"><p>The <code>node</code> parameter is a BinaryTreeNode object or null. It represents the
1751
1752
  root node of a binary tree. If it is null, the function will use the root node of the current binary tree instance.</p>
1752
1753
  </div>
@@ -1758,12 +1759,12 @@ specifies the property of the <code>BinaryTreeNode</code> object to collect at e
1758
1759
  values:</p>
1759
1760
  </div>
1760
1761
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1761
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>listLevels</code> returns a 2D array of <code>ResultByProperty&lt;T&gt;</code> objects.</p>
1762
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>listLevels</code> returns a 2D array of <code>AbstractResultByProperty&lt;N&gt;</code> objects.</p>
1762
1763
 
1763
1764
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1764
1765
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#listLevels">listLevels</a></p>
1765
1766
  <ul>
1766
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1140">src/data-structures/binary-tree/binary-tree.ts:1140</a></li></ul></aside></li></ul></section>
1767
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1136">src/data-structures/binary-tree/abstract-binary-tree.ts:1136</a></li></ul></aside></li></ul></section>
1767
1768
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="morris" class="tsd-anchor"></a>
1768
1769
  <h3 class="tsd-anchor-link"><span>morris</span><a href="#morris" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1769
1770
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1774,12 +1775,12 @@ traversal algorithm and returns the results based on the specified property name
1774
1775
  The time complexity of Morris traversal is O(n), it&#39;s may slower than others
1775
1776
  The space complexity Morris traversal is O(1) because no using stack</p>
1776
1777
  </div>
1777
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>morris</code> returns an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
1778
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>morris</code> returns an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
1778
1779
 
1779
1780
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1780
1781
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#morris">morris</a></p>
1781
1782
  <ul>
1782
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1223">src/data-structures/binary-tree/binary-tree.ts:1223</a></li></ul></aside></li>
1783
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1219">src/data-structures/binary-tree/abstract-binary-tree.ts:1219</a></li></ul></aside></li>
1783
1784
  <li class="tsd-signature tsd-anchor-link" id="morris.morris-2"><span class="tsd-kind-call-signature">morris</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><a href="#morris.morris-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1784
1785
  <li class="tsd-description">
1785
1786
  <div class="tsd-comment tsd-typography"><p>The <code>morris</code> function performs an in-order, pre-order, or post-order traversal on a binary tree using the Morris
@@ -1803,13 +1804,13 @@ property of the nodes that you want to retrieve in the results. It can be either
1803
1804
  property. If not provided, it defaults to <code>&#39;id&#39;</code>.</p>
1804
1805
  </div>
1805
1806
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1806
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>morris</code> returns an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
1807
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>morris</code> returns an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
1807
1808
 
1808
1809
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1809
1810
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#morris">morris</a></p>
1810
1811
  <ul>
1811
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1225">src/data-structures/binary-tree/binary-tree.ts:1225</a></li></ul></aside></li>
1812
- <li class="tsd-signature tsd-anchor-link" id="morris.morris-3"><span class="tsd-kind-call-signature">morris</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span><a href="#morris.morris-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1812
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1221">src/data-structures/binary-tree/abstract-binary-tree.ts:1221</a></li></ul></aside></li>
1813
+ <li class="tsd-signature tsd-anchor-link" id="morris.morris-3"><span class="tsd-kind-call-signature">morris</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><a href="#morris.morris-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1813
1814
  <li class="tsd-description">
1814
1815
  <div class="tsd-comment tsd-typography"><p>The <code>morris</code> function performs an in-order, pre-order, or post-order traversal on a binary tree using the Morris
1815
1816
  traversal algorithm and returns the results based on the specified property name.
@@ -1832,13 +1833,13 @@ property of the nodes that you want to retrieve in the results. It can be either
1832
1833
  property. If not provided, it defaults to <code>&#39;id&#39;</code>.</p>
1833
1834
  </div>
1834
1835
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1835
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>morris</code> returns an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
1836
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>morris</code> returns an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
1836
1837
 
1837
1838
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1838
1839
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#morris">morris</a></p>
1839
1840
  <ul>
1840
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1227">src/data-structures/binary-tree/binary-tree.ts:1227</a></li></ul></aside></li>
1841
- <li class="tsd-signature tsd-anchor-link" id="morris.morris-4"><span class="tsd-kind-call-signature">morris</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span><a href="#morris.morris-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1841
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1223">src/data-structures/binary-tree/abstract-binary-tree.ts:1223</a></li></ul></aside></li>
1842
+ <li class="tsd-signature tsd-anchor-link" id="morris.morris-4"><span class="tsd-kind-call-signature">morris</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span><a href="#morris.morris-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1842
1843
  <li class="tsd-description">
1843
1844
  <div class="tsd-comment tsd-typography"><p>The <code>morris</code> function performs an in-order, pre-order, or post-order traversal on a binary tree using the Morris
1844
1845
  traversal algorithm and returns the results based on the specified property name.
@@ -1861,12 +1862,12 @@ property of the nodes that you want to retrieve in the results. It can be either
1861
1862
  property. If not provided, it defaults to <code>&#39;id&#39;</code>.</p>
1862
1863
  </div>
1863
1864
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1864
- <h4 class="tsd-returns-title">Returns <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>morris</code> returns an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
1865
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>morris</code> returns an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
1865
1866
 
1866
1867
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1867
1868
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#morris">morris</a></p>
1868
1869
  <ul>
1869
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1229">src/data-structures/binary-tree/binary-tree.ts:1229</a></li></ul></aside></li>
1870
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1225">src/data-structures/binary-tree/abstract-binary-tree.ts:1225</a></li></ul></aside></li>
1870
1871
  <li class="tsd-signature tsd-anchor-link" id="morris.morris-5"><span class="tsd-kind-call-signature">morris</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">pattern</span><span class="tsd-signature-symbol">?</span>, <span class="tsd-kind-parameter">nodeOrPropertyName</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><a href="#morris.morris-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1871
1872
  <li class="tsd-description">
1872
1873
  <div class="tsd-comment tsd-typography"><p>The <code>morris</code> function performs an in-order, pre-order, or post-order traversal on a binary tree using the Morris
@@ -1890,42 +1891,42 @@ property of the nodes that you want to retrieve in the results. It can be either
1890
1891
  property. If not provided, it defaults to <code>&#39;id&#39;</code>.</p>
1891
1892
  </div>
1892
1893
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1893
- <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>morris</code> returns an object of type <code>ResultsByProperty&lt;T&gt;</code>.</p>
1894
+ <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span></h4><p>The function <code>morris</code> returns an object of type <code>AbstractResultsByProperty&lt;N&gt;</code>.</p>
1894
1895
 
1895
1896
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1896
1897
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#morris">morris</a></p>
1897
1898
  <ul>
1898
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1231">src/data-structures/binary-tree/binary-tree.ts:1231</a></li></ul></aside></li></ul></section>
1899
- <section class="tsd-panel tsd-member"><a id="remove" class="tsd-anchor"></a>
1899
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1227">src/data-structures/binary-tree/abstract-binary-tree.ts:1227</a></li></ul></aside></li></ul></section>
1900
+ <section class="tsd-panel tsd-member tsd-is-inherited"><a id="remove" class="tsd-anchor"></a>
1900
1901
  <h3 class="tsd-anchor-link"><span>remove</span><a href="#remove" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1901
- <ul class="tsd-signatures">
1902
- <li class="tsd-signature tsd-anchor-link" id="remove.remove-1"><span class="tsd-kind-call-signature">remove</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">id</span>, <span class="tsd-kind-parameter">isUpdateAllLeftSum</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="../types/TreeMultiSetDeletedResult.html" class="tsd-signature-type tsd-kind-type-alias">TreeMultiSetDeletedResult</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span><a href="#remove.remove-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1902
+ <ul class="tsd-signatures tsd-is-inherited">
1903
+ <li class="tsd-signature tsd-anchor-link" id="remove.remove-1"><span class="tsd-kind-call-signature">remove</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">id</span>, <span class="tsd-kind-parameter">ignoreCount</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="../types/BinaryTreeDeletedResult.html" class="tsd-signature-type tsd-kind-type-alias">BinaryTreeDeletedResult</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span><a href="#remove.remove-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></li>
1903
1904
  <li class="tsd-description">
1904
- <div class="tsd-comment tsd-typography"><p>The function overrides the remove method of the superclass and returns the result of calling the superclass&#39;s remove
1905
- method.</p>
1905
+ <div class="tsd-comment tsd-typography"><p>The <code>remove</code> function in this TypeScript code removes a node from a binary search tree and returns information about
1906
+ the deleted node and any nodes that need to be balanced.</p>
1906
1907
  </div>
1907
1908
  <div class="tsd-parameters">
1908
1909
  <h4 class="tsd-parameters-title">Parameters</h4>
1909
1910
  <ul class="tsd-parameter-list">
1910
1911
  <li>
1911
1912
  <h5><span class="tsd-kind-parameter">id</span>: <span class="tsd-signature-type">number</span></h5>
1912
- <div class="tsd-comment tsd-typography"><p>The <code>id</code> parameter represents the identifier of the binary tree node that needs to be
1913
- removed from the tree.</p>
1913
+ <div class="tsd-comment tsd-typography"><p>The <code>id</code> parameter is the identifier of the binary tree node that needs to be removed
1914
+ from the binary search tree.</p>
1914
1915
  </div>
1915
1916
  <div class="tsd-comment tsd-typography"></div></li>
1916
1917
  <li>
1917
- <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">isUpdateAllLeftSum</span>: <span class="tsd-signature-type">boolean</span></h5>
1918
- <div class="tsd-comment tsd-typography"><p>The <code>isUpdateAllLeftSum</code> parameter is an optional boolean value that
1919
- determines whether to update the left sum of all nodes in the tree after removing a node. If <code>isUpdateAllLeftSum</code> is
1920
- set to <code>true</code>, the left sum of all nodes will be recalculated. If it</p>
1918
+ <h5><code class="tsd-tag ts-flagOptional">Optional</code> <span class="tsd-kind-parameter">ignoreCount</span>: <span class="tsd-signature-type">boolean</span></h5>
1919
+ <div class="tsd-comment tsd-typography"><p>A boolean flag indicating whether to ignore the count of the node being removed. If
1920
+ set to true, the count of the node will not be considered and the node will be removed regardless of its count. If
1921
+ set to false or not provided, the count of the node will be taken into account and the</p>
1921
1922
  </div>
1922
1923
  <div class="tsd-comment tsd-typography"></div></li></ul></div>
1923
- <h4 class="tsd-returns-title">Returns <a href="../types/TreeMultiSetDeletedResult.html" class="tsd-signature-type tsd-kind-type-alias">TreeMultiSetDeletedResult</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h4><p>The method is returning an array of TreeMultiSetDeletedResult objects.</p>
1924
+ <h4 class="tsd-returns-title">Returns <a href="../types/BinaryTreeDeletedResult.html" class="tsd-signature-type tsd-kind-type-alias">BinaryTreeDeletedResult</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">N</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">[]</span></h4><p>an array of <code>BSTDeletedResult&lt;N&gt;</code> objects.</p>
1924
1925
 
1925
1926
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1926
- <p>Overrides <a href="BST.html">BST</a>.<a href="BST.html#remove">remove</a></p>
1927
+ <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#remove">remove</a></p>
1927
1928
  <ul>
1928
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/tree-multiset.ts#L48">src/data-structures/binary-tree/tree-multiset.ts:48</a></li></ul></aside></li></ul></section>
1929
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/bst.ts#L152">src/data-structures/binary-tree/bst.ts:152</a></li></ul></aside></li></ul></section>
1929
1930
  <section class="tsd-panel tsd-member tsd-is-protected tsd-is-inherited"><a id="setVisitedCount" class="tsd-anchor"></a>
1930
1931
  <h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagProtected">Protected</code> <span>set<wbr/>Visited<wbr/>Count</span><a href="#setVisitedCount" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1931
1932
  <ul class="tsd-signatures tsd-is-protected tsd-is-inherited">
@@ -1939,7 +1940,7 @@ set to <code>true</code>, the left sum of all nodes will be recalculated. If it<
1939
1940
  <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
1940
1941
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#setVisitedCount">setVisitedCount</a></p>
1941
1942
  <ul>
1942
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L1347">src/data-structures/binary-tree/binary-tree.ts:1347</a></li></ul></aside></li></ul></section>
1943
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L1343">src/data-structures/binary-tree/abstract-binary-tree.ts:1343</a></li></ul></aside></li></ul></section>
1943
1944
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="subTreeAdd" class="tsd-anchor"></a>
1944
1945
  <h3 class="tsd-anchor-link"><span>sub<wbr/>Tree<wbr/>Add</span><a href="#subTreeAdd" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1945
1946
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1951,7 +1952,7 @@ set to <code>true</code>, the left sum of all nodes will be recalculated. If it<
1951
1952
  <h4 class="tsd-parameters-title">Parameters</h4>
1952
1953
  <ul class="tsd-parameter-list">
1953
1954
  <li>
1954
- <h5><span class="tsd-kind-parameter">subTreeRoot</span>: <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1955
+ <h5><span class="tsd-kind-parameter">subTreeRoot</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1955
1956
  <div class="tsd-comment tsd-typography"><p>The <code>subTreeRoot</code> parameter is the root node of the subtree where the values will be modified.</p>
1956
1957
  </div>
1957
1958
  <div class="tsd-comment tsd-typography"></div></li>
@@ -1972,7 +1973,7 @@ specifies the property of the <code>BinaryTreeNode</code> that should be modifie
1972
1973
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
1973
1974
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#subTreeAdd">subTreeAdd</a></p>
1974
1975
  <ul>
1975
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L900">src/data-structures/binary-tree/binary-tree.ts:900</a></li></ul></aside></li></ul></section>
1976
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L896">src/data-structures/binary-tree/abstract-binary-tree.ts:896</a></li></ul></aside></li></ul></section>
1976
1977
  <section class="tsd-panel tsd-member tsd-is-inherited"><a id="subTreeSum" class="tsd-anchor"></a>
1977
1978
  <h3 class="tsd-anchor-link"><span>sub<wbr/>Tree<wbr/>Sum</span><a href="#subTreeSum" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="#icon-anchor"></use></svg></a></h3>
1978
1979
  <ul class="tsd-signatures tsd-is-inherited">
@@ -1985,7 +1986,7 @@ iteratively.</p>
1985
1986
  <h4 class="tsd-parameters-title">Parameters</h4>
1986
1987
  <ul class="tsd-parameter-list">
1987
1988
  <li>
1988
- <h5><span class="tsd-kind-parameter">subTreeRoot</span>: <a href="BinaryTreeNode.html" class="tsd-signature-type tsd-kind-class">BinaryTreeNode</a><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type tsd-kind-type-parameter">T</span><span class="tsd-signature-symbol">&gt;</span></h5>
1989
+ <h5><span class="tsd-kind-parameter">subTreeRoot</span>: <span class="tsd-signature-type tsd-kind-type-parameter">N</span></h5>
1989
1990
  <div class="tsd-comment tsd-typography"><p>The subTreeRoot parameter is the root node of the subtree for which you want to calculate the
1990
1991
  sum.</p>
1991
1992
  </div>
@@ -2002,7 +2003,7 @@ provided, it defaults to <code>&#39;val&#39;</code>.</p>
2002
2003
  <div class="tsd-comment tsd-typography"></div><aside class="tsd-sources">
2003
2004
  <p>Inherited from <a href="BST.html">BST</a>.<a href="BST.html#subTreeSum">subTreeSum</a></p>
2004
2005
  <ul>
2005
- <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/c1b5969/src/data-structures/binary-tree/binary-tree.ts#L844">src/data-structures/binary-tree/binary-tree.ts:844</a></li></ul></aside></li></ul></section></section></div>
2006
+ <li>Defined in <a href="https://github.com/zrwusa/data-structure-typed/blob/860d18d/src/data-structures/binary-tree/abstract-binary-tree.ts#L840">src/data-structures/binary-tree/abstract-binary-tree.ts:840</a></li></ul></aside></li></ul></section></section></div>
2006
2007
  <div class="col-sidebar">
2007
2008
  <div class="page-menu">
2008
2009
  <div class="tsd-navigation settings">
@@ -2022,7 +2023,7 @@ provided, it defaults to <code>&#39;val&#39;</code>.</p>
2022
2023
  <h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="#icon-chevronDown"></use></svg>On This Page</h3></summary>
2023
2024
  <div class="tsd-accordion-details">
2024
2025
  <ul>
2025
- <li><a href="#constructor" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-512"></use></svg><span>constructor</span></a></li>
2026
+ <li><a href="#constructor" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-512"></use></svg><span>constructor</span></a></li>
2026
2027
  <li><a href="#_comparator" class="tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-1024"></use></svg><span>_comparator</span></a></li>
2027
2028
  <li><a href="#autoIncrementId" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-262144"></use></svg><span>auto<wbr/>Increment<wbr/>Id</span></a></li>
2028
2029
  <li><a href="#count" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-262144"></use></svg><span>count</span></a></li>
@@ -2041,6 +2042,7 @@ provided, it defaults to <code>&#39;val&#39;</code>.</p>
2041
2042
  <li><a href="#DFSIterative" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>DFSIterative</span></a></li>
2042
2043
  <li><a href="#_accumulatedByPropertyName" class="tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_accumulated<wbr/>By<wbr/>Property<wbr/>Name</span></a></li>
2043
2044
  <li><a href="#_compare" class="tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_compare</span></a></li>
2045
+ <li><a href="#_createNode" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_create<wbr/>Node</span></a></li>
2044
2046
  <li><a href="#_getResultByPropertyName" class="tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_get<wbr/>Result<wbr/>By<wbr/>Property<wbr/>Name</span></a></li>
2045
2047
  <li><a href="#_pushByPropertyNameStopOrNot" class="tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_push<wbr/>By<wbr/>Property<wbr/>Name<wbr/>Stop<wbr/>Or<wbr/>Not</span></a></li>
2046
2048
  <li><a href="#_resetResults" class="tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_reset<wbr/>Results</span></a></li>
@@ -2055,13 +2057,12 @@ provided, it defaults to <code>&#39;val&#39;</code>.</p>
2055
2057
  <li><a href="#_setVisitedLeftSum" class="tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_set<wbr/>Visited<wbr/>Left<wbr/>Sum</span></a></li>
2056
2058
  <li><a href="#_setVisitedNode" class="tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_set<wbr/>Visited<wbr/>Node</span></a></li>
2057
2059
  <li><a href="#_setVisitedVal" class="tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>_set<wbr/>Visited<wbr/>Val</span></a></li>
2058
- <li><a href="#add" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>add</span></a></li>
2060
+ <li><a href="#add" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>add</span></a></li>
2059
2061
  <li><a href="#addMany" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>add<wbr/>Many</span></a></li>
2060
2062
  <li><a href="#addTo" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>add<wbr/>To</span></a></li>
2061
2063
  <li><a href="#allGreaterNodesAdd" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>all<wbr/>Greater<wbr/>Nodes<wbr/>Add</span></a></li>
2062
2064
  <li><a href="#balance" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>balance</span></a></li>
2063
2065
  <li><a href="#clear" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>clear</span></a></li>
2064
- <li><a href="#createNode" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>create<wbr/>Node</span></a></li>
2065
2066
  <li><a href="#fill" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>fill</span></a></li>
2066
2067
  <li><a href="#get" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>get</span></a></li>
2067
2068
  <li><a href="#getDepth" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>get<wbr/>Depth</span></a></li>
@@ -2083,7 +2084,7 @@ provided, it defaults to <code>&#39;val&#39;</code>.</p>
2083
2084
  <li><a href="#levelIterative" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>level<wbr/>Iterative</span></a></li>
2084
2085
  <li><a href="#listLevels" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>list<wbr/>Levels</span></a></li>
2085
2086
  <li><a href="#morris" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>morris</span></a></li>
2086
- <li><a href="#remove" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>remove</span></a></li>
2087
+ <li><a href="#remove" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>remove</span></a></li>
2087
2088
  <li><a href="#setVisitedCount" class="tsd-is-protected tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>set<wbr/>Visited<wbr/>Count</span></a></li>
2088
2089
  <li><a href="#subTreeAdd" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>sub<wbr/>Tree<wbr/>Add</span></a></li>
2089
2090
  <li><a href="#subTreeSum" class="tsd-is-inherited"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-2048"></use></svg><span>sub<wbr/>Tree<wbr/>Sum</span></a></li></ul></div></details></div>
@@ -2093,9 +2094,13 @@ provided, it defaults to <code>&#39;val&#39;</code>.</p>
2093
2094
  <li><a href="../enums/CP.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><g id="icon-8"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-enum)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.45 16V7.24H14.49V8.224H10.518V10.936H14.07V11.908H10.518V15.016H14.49V16H9.45Z" fill="var(--color-text)"></path></g></svg><span>CP</span></a></li>
2094
2095
  <li><a href="../enums/FamilyPosition.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-8"></use></svg><span>Family<wbr/>Position</span></a></li>
2095
2096
  <li><a href="../enums/LoopType.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-8"></use></svg><span>Loop<wbr/>Type</span></a></li>
2097
+ <li><a href="../enums/RBColor.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-8"></use></svg><span>RBColor</span></a></li>
2098
+ <li><a href="../enums/TopologicalProperty.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-8"></use></svg><span>Topological<wbr/>Property</span></a></li>
2096
2099
  <li><a href="AVLTree.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><g id="icon-128"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-class)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)"></path></g></svg><span>AVLTree</span></a></li>
2097
2100
  <li><a href="AVLTreeNode.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>AVLTree<wbr/>Node</span></a></li>
2098
2101
  <li><a href="AaTree.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Aa<wbr/>Tree</span></a></li>
2102
+ <li><a href="AbstractBinaryTree.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Abstract<wbr/>Binary<wbr/>Tree</span></a></li>
2103
+ <li><a href="AbstractBinaryTreeNode.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Abstract<wbr/>Binary<wbr/>Tree<wbr/>Node</span></a></li>
2099
2104
  <li><a href="AbstractEdge.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Abstract<wbr/>Edge</span></a></li>
2100
2105
  <li><a href="AbstractGraph.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Abstract<wbr/>Graph</span></a></li>
2101
2106
  <li><a href="AbstractVertex.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Abstract<wbr/>Vertex</span></a></li>
@@ -2129,7 +2134,6 @@ provided, it defaults to <code>&#39;val&#39;</code>.</p>
2129
2134
  <li><a href="Pair.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Pair</span></a></li>
2130
2135
  <li><a href="PriorityQueue.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Priority<wbr/>Queue</span></a></li>
2131
2136
  <li><a href="Queue.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Queue</span></a></li>
2132
- <li><a href="RBTree.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>RBTree</span></a></li>
2133
2137
  <li><a href="SegmentTree.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Segment<wbr/>Tree</span></a></li>
2134
2138
  <li><a href="SegmentTreeNode.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Segment<wbr/>Tree<wbr/>Node</span></a></li>
2135
2139
  <li><a href="SinglyLinkedList.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Singly<wbr/>Linked<wbr/>List</span></a></li>
@@ -2139,6 +2143,7 @@ provided, it defaults to <code>&#39;val&#39;</code>.</p>
2139
2143
  <li><a href="Stack.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Stack</span></a></li>
2140
2144
  <li><a href="TreeMap.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Tree<wbr/>Map</span></a></li>
2141
2145
  <li><a href="TreeMultiSet.html" class="current"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Tree<wbr/>Multi<wbr/>Set</span></a></li>
2146
+ <li><a href="TreeMultiSetNode.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Tree<wbr/>Multi<wbr/>Set<wbr/>Node</span></a></li>
2142
2147
  <li><a href="TreeNode.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Tree<wbr/>Node</span></a></li>
2143
2148
  <li><a href="TreeSet.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Tree<wbr/>Set</span></a></li>
2144
2149
  <li><a href="Trie.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Trie</span></a></li>
@@ -2148,33 +2153,42 @@ provided, it defaults to <code>&#39;val&#39;</code>.</p>
2148
2153
  <li><a href="UndirectedGraph.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Undirected<wbr/>Graph</span></a></li>
2149
2154
  <li><a href="UndirectedVertex.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Undirected<wbr/>Vertex</span></a></li>
2150
2155
  <li><a href="Vector2D.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-128"></use></svg><span>Vector2D</span></a></li>
2151
- <li><a href="../interfaces/AVLTreeDeleted.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><g id="icon-256"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-interface)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.51 16V15.016H11.298V8.224H9.51V7.24H14.19V8.224H12.402V15.016H14.19V16H9.51Z" fill="var(--color-text)"></path></g></svg><span>AVLTree<wbr/>Deleted</span></a></li>
2152
- <li><a href="../interfaces/HeapOptions.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-256"></use></svg><span>Heap<wbr/>Options</span></a></li>
2156
+ <li><a href="../interfaces/IBinaryTree.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><g id="icon-256"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-interface)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M9.51 16V15.016H11.298V8.224H9.51V7.24H14.19V8.224H12.402V15.016H14.19V16H9.51Z" fill="var(--color-text)"></path></g></svg><span>IBinary<wbr/>Tree</span></a></li>
2157
+ <li><a href="../interfaces/IBinaryTreeNode.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-256"></use></svg><span>IBinary<wbr/>Tree<wbr/>Node</span></a></li>
2153
2158
  <li><a href="../interfaces/IDirectedGraph.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-256"></use></svg><span>IDirected<wbr/>Graph</span></a></li>
2154
2159
  <li><a href="../interfaces/IGraph.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-256"></use></svg><span>IGraph</span></a></li>
2155
- <li><a href="../interfaces/NavigatorParams.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-256"></use></svg><span>Navigator<wbr/>Params</span></a></li>
2156
- <li><a href="../interfaces/PriorityQueueOptions.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-256"></use></svg><span>Priority<wbr/>Queue<wbr/>Options</span></a></li>
2157
- <li><a href="../types/BSTComparator.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><g id="icon-4194304"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-type-alias)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.31 16V8.224H8.91V7.24H14.79V8.224H12.39V16H11.31Z" fill="var(--color-text)"></path></g></svg><span>BSTComparator</span></a></li>
2158
- <li><a href="../types/BSTDeletedResult.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>BSTDeleted<wbr/>Result</span></a></li>
2159
- <li><a href="../types/BinaryTreeDeleted.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Binary<wbr/>Tree<wbr/>Deleted</span></a></li>
2160
+ <li><a href="../interfaces/IUNDirectedGraph.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-256"></use></svg><span>IUNDirected<wbr/>Graph</span></a></li>
2161
+ <li><a href="../types/AVLTreeOptions.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><g id="icon-4194304"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-type-alias)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6"></rect><path d="M11.31 16V8.224H8.91V7.24H14.79V8.224H12.39V16H11.31Z" fill="var(--color-text)"></path></g></svg><span>AVLTree<wbr/>Options</span></a></li>
2162
+ <li><a href="../types/AbstractBinaryTreeOptions.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Abstract<wbr/>Binary<wbr/>Tree<wbr/>Options</span></a></li>
2163
+ <li><a href="../types/AbstractRecursiveBinaryTreeNode.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Abstract<wbr/>Recursive<wbr/>Binary<wbr/>Tree<wbr/>Node</span></a></li>
2164
+ <li><a href="../types/AbstractResultByProperty.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Abstract<wbr/>Result<wbr/>By<wbr/>Property</span></a></li>
2165
+ <li><a href="../types/AbstractResultsByProperty.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Abstract<wbr/>Results<wbr/>By<wbr/>Property</span></a></li>
2166
+ <li><a href="../types/BSTComparator.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>BSTComparator</span></a></li>
2167
+ <li><a href="../types/BSTOptions.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>BSTOptions</span></a></li>
2168
+ <li><a href="../types/BinaryTreeDeletedResult.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Binary<wbr/>Tree<wbr/>Deleted<wbr/>Result</span></a></li>
2160
2169
  <li><a href="../types/BinaryTreeNodeId.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Binary<wbr/>Tree<wbr/>Node<wbr/>Id</span></a></li>
2161
2170
  <li><a href="../types/BinaryTreeNodePropertyName.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Binary<wbr/>Tree<wbr/>Node<wbr/>Property<wbr/>Name</span></a></li>
2171
+ <li><a href="../types/BinaryTreeOptions.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Binary<wbr/>Tree<wbr/>Options</span></a></li>
2162
2172
  <li><a href="../types/DFSOrderPattern.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>DFSOrder<wbr/>Pattern</span></a></li>
2163
2173
  <li><a href="../types/DijkstraResult.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Dijkstra<wbr/>Result</span></a></li>
2164
2174
  <li><a href="../types/Direction.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Direction</span></a></li>
2175
+ <li><a href="../types/EdgeId.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Edge<wbr/>Id</span></a></li>
2176
+ <li><a href="../types/HeapOptions.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Heap<wbr/>Options</span></a></li>
2177
+ <li><a href="../types/IdObject.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Id<wbr/>Object</span></a></li>
2178
+ <li><a href="../types/KeyValObject.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Key<wbr/>Val<wbr/>Object</span></a></li>
2179
+ <li><a href="../types/NavigatorParams.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Navigator<wbr/>Params</span></a></li>
2165
2180
  <li><a href="../types/NodeOrPropertyName.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Node<wbr/>Or<wbr/>Property<wbr/>Name</span></a></li>
2166
2181
  <li><a href="../types/PriorityQueueComparator.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Priority<wbr/>Queue<wbr/>Comparator</span></a></li>
2167
2182
  <li><a href="../types/PriorityQueueDFSOrderPattern.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Priority<wbr/>QueueDFSOrder<wbr/>Pattern</span></a></li>
2168
- <li><a href="../types/ResultByProperty.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Result<wbr/>By<wbr/>Property</span></a></li>
2169
- <li><a href="../types/ResultsByProperty.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Results<wbr/>By<wbr/>Property</span></a></li>
2183
+ <li><a href="../types/PriorityQueueOptions.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Priority<wbr/>Queue<wbr/>Options</span></a></li>
2184
+ <li><a href="../types/RBTreeOptions.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>RBTree<wbr/>Options</span></a></li>
2185
+ <li><a href="../types/RecursiveAVLTreeNode.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>RecursiveAVLTree<wbr/>Node</span></a></li>
2186
+ <li><a href="../types/RecursiveBSTNode.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>RecursiveBSTNode</span></a></li>
2187
+ <li><a href="../types/RecursiveBinaryTreeNode.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Recursive<wbr/>Binary<wbr/>Tree<wbr/>Node</span></a></li>
2188
+ <li><a href="../types/RecursiveTreeMultiSetNode.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Recursive<wbr/>Tree<wbr/>Multi<wbr/>Set<wbr/>Node</span></a></li>
2170
2189
  <li><a href="../types/SegmentTreeNodeVal.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Segment<wbr/>Tree<wbr/>Node<wbr/>Val</span></a></li>
2171
- <li><a href="../types/SpecifyOptional.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Specify<wbr/>Optional</span></a></li>
2172
- <li><a href="../types/Thunk.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Thunk</span></a></li>
2173
- <li><a href="../types/ToThunkFn.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>To<wbr/>Thunk<wbr/>Fn</span></a></li>
2174
2190
  <li><a href="../types/TopologicalStatus.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Topological<wbr/>Status</span></a></li>
2175
- <li><a href="../types/TreeMultiSetDeletedResult.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Tree<wbr/>Multi<wbr/>Set<wbr/>Deleted<wbr/>Result</span></a></li>
2176
- <li><a href="../types/TrlAsyncFn.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Trl<wbr/>Async<wbr/>Fn</span></a></li>
2177
- <li><a href="../types/TrlFn.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Trl<wbr/>Fn</span></a></li>
2191
+ <li><a href="../types/TreeMultiSetOptions.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Tree<wbr/>Multi<wbr/>Set<wbr/>Options</span></a></li>
2178
2192
  <li><a href="../types/Turning.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Turning</span></a></li>
2179
2193
  <li><a href="../types/VertexId.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="#icon-4194304"></use></svg><span>Vertex<wbr/>Id</span></a></li></ul></nav></div></div></div>
2180
2194
  <div class="tsd-generator">