binary-tree-typed 2.5.2 → 2.5.3
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.
- package/dist/cjs/index.cjs +194 -55
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/cjs-legacy/index.cjs +194 -55
- package/dist/cjs-legacy/index.cjs.map +1 -1
- package/dist/esm/index.mjs +194 -55
- package/dist/esm/index.mjs.map +1 -1
- package/dist/esm-legacy/index.mjs +194 -55
- package/dist/esm-legacy/index.mjs.map +1 -1
- package/dist/types/data-structures/binary-tree/avl-tree.d.ts +50 -2
- package/dist/types/data-structures/binary-tree/binary-indexed-tree.d.ts +56 -0
- package/dist/types/data-structures/binary-tree/binary-tree.d.ts +116 -15
- package/dist/types/data-structures/binary-tree/bst.d.ts +99 -3
- package/dist/types/data-structures/binary-tree/red-black-tree.d.ts +79 -8
- package/dist/types/data-structures/binary-tree/segment-tree.d.ts +24 -0
- package/dist/types/data-structures/binary-tree/tree-map.d.ts +520 -1
- package/dist/types/data-structures/binary-tree/tree-multi-map.d.ts +489 -1
- package/dist/types/data-structures/binary-tree/tree-multi-set.d.ts +393 -1
- package/dist/types/data-structures/binary-tree/tree-set.d.ts +500 -1
- package/dist/types/data-structures/graph/directed-graph.d.ts +40 -0
- package/dist/types/data-structures/graph/undirected-graph.d.ts +36 -0
- package/dist/types/data-structures/hash/hash-map.d.ts +51 -6
- package/dist/types/data-structures/heap/heap.d.ts +98 -12
- package/dist/types/data-structures/linked-list/doubly-linked-list.d.ts +75 -0
- package/dist/types/data-structures/linked-list/singly-linked-list.d.ts +61 -1
- package/dist/types/data-structures/linked-list/skip-linked-list.d.ts +72 -0
- package/dist/types/data-structures/matrix/matrix.d.ts +32 -0
- package/dist/types/data-structures/queue/deque.d.ts +82 -0
- package/dist/types/data-structures/queue/queue.d.ts +61 -0
- package/dist/types/data-structures/stack/stack.d.ts +42 -2
- package/dist/types/data-structures/trie/trie.d.ts +48 -0
- package/dist/types/interfaces/binary-tree.d.ts +2 -3
- package/dist/umd/binary-tree-typed.js +194 -55
- package/dist/umd/binary-tree-typed.js.map +1 -1
- package/dist/umd/binary-tree-typed.min.js +5 -5
- package/dist/umd/binary-tree-typed.min.js.map +1 -1
- package/package.json +2 -2
- package/src/data-structures/binary-tree/avl-tree.ts +52 -5
- package/src/data-structures/binary-tree/binary-indexed-tree.ts +56 -0
- package/src/data-structures/binary-tree/binary-tree.ts +167 -81
- package/src/data-structures/binary-tree/bst.ts +101 -7
- package/src/data-structures/binary-tree/red-black-tree.ts +82 -15
- package/src/data-structures/binary-tree/segment-tree.ts +24 -0
- package/src/data-structures/binary-tree/tree-map.ts +540 -3
- package/src/data-structures/binary-tree/tree-multi-map.ts +490 -2
- package/src/data-structures/binary-tree/tree-multi-set.ts +393 -1
- package/src/data-structures/binary-tree/tree-set.ts +520 -3
- package/src/data-structures/graph/directed-graph.ts +41 -1
- package/src/data-structures/graph/undirected-graph.ts +37 -1
- package/src/data-structures/hash/hash-map.ts +67 -12
- package/src/data-structures/heap/heap.ts +107 -19
- package/src/data-structures/linked-list/doubly-linked-list.ts +88 -0
- package/src/data-structures/linked-list/singly-linked-list.ts +61 -1
- package/src/data-structures/linked-list/skip-linked-list.ts +72 -0
- package/src/data-structures/matrix/matrix.ts +32 -0
- package/src/data-structures/queue/deque.ts +85 -0
- package/src/data-structures/queue/queue.ts +73 -0
- package/src/data-structures/stack/stack.ts +45 -5
- package/src/data-structures/trie/trie.ts +48 -0
- package/src/interfaces/binary-tree.ts +1 -9
|
@@ -795,6 +795,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
795
795
|
|
|
796
796
|
|
|
797
797
|
|
|
798
|
+
|
|
799
|
+
|
|
800
|
+
|
|
801
|
+
|
|
798
802
|
|
|
799
803
|
|
|
800
804
|
|
|
@@ -845,6 +849,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
845
849
|
|
|
846
850
|
|
|
847
851
|
|
|
852
|
+
|
|
853
|
+
|
|
854
|
+
|
|
855
|
+
|
|
848
856
|
|
|
849
857
|
|
|
850
858
|
|
|
@@ -859,6 +867,14 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
859
867
|
get first() {
|
|
860
868
|
return this.length > 0 ? this.elements[this._offset] : void 0;
|
|
861
869
|
}
|
|
870
|
+
/**
|
|
871
|
+
* Peek at the front element without removing it (alias for `first`).
|
|
872
|
+
* @remarks Time O(1), Space O(1)
|
|
873
|
+
* @returns Front element or undefined.
|
|
874
|
+
*/
|
|
875
|
+
peek() {
|
|
876
|
+
return this.first;
|
|
877
|
+
}
|
|
862
878
|
/**
|
|
863
879
|
* Get the last element (back) without removing it.
|
|
864
880
|
* @remarks Time O(1), Space O(1)
|
|
@@ -911,6 +927,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
911
927
|
|
|
912
928
|
|
|
913
929
|
|
|
930
|
+
|
|
931
|
+
|
|
932
|
+
|
|
933
|
+
|
|
914
934
|
|
|
915
935
|
|
|
916
936
|
|
|
@@ -973,6 +993,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
973
993
|
|
|
974
994
|
|
|
975
995
|
|
|
996
|
+
|
|
997
|
+
|
|
998
|
+
|
|
999
|
+
|
|
976
1000
|
|
|
977
1001
|
|
|
978
1002
|
|
|
@@ -1042,6 +1066,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
1042
1066
|
|
|
1043
1067
|
|
|
1044
1068
|
|
|
1069
|
+
|
|
1070
|
+
|
|
1071
|
+
|
|
1072
|
+
|
|
1045
1073
|
|
|
1046
1074
|
|
|
1047
1075
|
|
|
@@ -1101,6 +1129,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
1101
1129
|
|
|
1102
1130
|
|
|
1103
1131
|
|
|
1132
|
+
|
|
1133
|
+
|
|
1134
|
+
|
|
1135
|
+
|
|
1104
1136
|
|
|
1105
1137
|
|
|
1106
1138
|
|
|
@@ -1153,6 +1185,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
1153
1185
|
|
|
1154
1186
|
|
|
1155
1187
|
|
|
1188
|
+
|
|
1189
|
+
|
|
1190
|
+
|
|
1191
|
+
|
|
1156
1192
|
|
|
1157
1193
|
|
|
1158
1194
|
|
|
@@ -1204,6 +1240,21 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
1204
1240
|
this._elements[this._offset + index] = newElement;
|
|
1205
1241
|
return true;
|
|
1206
1242
|
}
|
|
1243
|
+
/**
|
|
1244
|
+
* Delete the first element that satisfies a predicate.
|
|
1245
|
+
* @remarks Time O(N), Space O(N)
|
|
1246
|
+
* @param predicate - Function (value, index, queue) → boolean to decide deletion.
|
|
1247
|
+
* @returns True if a match was removed.
|
|
1248
|
+
*/
|
|
1249
|
+
deleteWhere(predicate) {
|
|
1250
|
+
for (let i = 0; i < this.length; i++) {
|
|
1251
|
+
if (predicate(this._elements[this._offset + i], i, this)) {
|
|
1252
|
+
this.deleteAt(i);
|
|
1253
|
+
return true;
|
|
1254
|
+
}
|
|
1255
|
+
}
|
|
1256
|
+
return false;
|
|
1257
|
+
}
|
|
1207
1258
|
/**
|
|
1208
1259
|
* Reverse the queue in-place by compacting then reversing.
|
|
1209
1260
|
* @remarks Time O(N), Space O(N)
|
|
@@ -1246,6 +1297,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
1246
1297
|
|
|
1247
1298
|
|
|
1248
1299
|
|
|
1300
|
+
|
|
1301
|
+
|
|
1302
|
+
|
|
1303
|
+
|
|
1249
1304
|
|
|
1250
1305
|
|
|
1251
1306
|
|
|
@@ -1292,6 +1347,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
1292
1347
|
|
|
1293
1348
|
|
|
1294
1349
|
|
|
1350
|
+
|
|
1351
|
+
|
|
1352
|
+
|
|
1353
|
+
|
|
1295
1354
|
|
|
1296
1355
|
|
|
1297
1356
|
|
|
@@ -1361,6 +1420,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
1361
1420
|
|
|
1362
1421
|
|
|
1363
1422
|
|
|
1423
|
+
|
|
1424
|
+
|
|
1425
|
+
|
|
1426
|
+
|
|
1364
1427
|
|
|
1365
1428
|
|
|
1366
1429
|
|
|
@@ -1414,6 +1477,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
1414
1477
|
|
|
1415
1478
|
|
|
1416
1479
|
|
|
1480
|
+
|
|
1481
|
+
|
|
1482
|
+
|
|
1483
|
+
|
|
1417
1484
|
|
|
1418
1485
|
|
|
1419
1486
|
|
|
@@ -1471,6 +1538,10 @@ var _Queue = class _Queue extends LinearBase {
|
|
|
1471
1538
|
|
|
1472
1539
|
|
|
1473
1540
|
|
|
1541
|
+
|
|
1542
|
+
|
|
1543
|
+
|
|
1544
|
+
|
|
1474
1545
|
|
|
1475
1546
|
|
|
1476
1547
|
|
|
@@ -1950,7 +2021,7 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
1950
2021
|
}
|
|
1951
2022
|
/**
|
|
1952
2023
|
* Adds a new node to the tree.
|
|
1953
|
-
* @remarks Time O(
|
|
2024
|
+
* @remarks Time O(N) — level-order traversal to find an empty slot. Space O(N) for the BFS queue. BST/Red-Black Tree/AVL Tree subclasses override to O(log N).
|
|
1954
2025
|
*
|
|
1955
2026
|
* @param keyNodeOrEntry - The key, node, or entry to add.
|
|
1956
2027
|
* @returns True if the addition was successful, false otherwise.
|
|
@@ -1979,6 +2050,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
1979
2050
|
|
|
1980
2051
|
|
|
1981
2052
|
|
|
2053
|
+
|
|
2054
|
+
|
|
2055
|
+
|
|
2056
|
+
|
|
1982
2057
|
|
|
1983
2058
|
|
|
1984
2059
|
|
|
@@ -1998,7 +2073,7 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
1998
2073
|
}
|
|
1999
2074
|
/**
|
|
2000
2075
|
* Adds or updates a new node to the tree.
|
|
2001
|
-
* @remarks Time O(
|
|
2076
|
+
* @remarks Time O(N) — level-order traversal to find an empty slot. Space O(N) for the BFS queue. BST/Red-Black Tree/AVL Tree subclasses override to O(log N).
|
|
2002
2077
|
*
|
|
2003
2078
|
* @param keyNodeOrEntry - The key, node, or entry to set or update.
|
|
2004
2079
|
* @param [value] - The value, if providing just a key.
|
|
@@ -2033,6 +2108,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2033
2108
|
|
|
2034
2109
|
|
|
2035
2110
|
|
|
2111
|
+
|
|
2112
|
+
|
|
2113
|
+
|
|
2114
|
+
|
|
2036
2115
|
|
|
2037
2116
|
|
|
2038
2117
|
|
|
@@ -2139,6 +2218,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2139
2218
|
|
|
2140
2219
|
|
|
2141
2220
|
|
|
2221
|
+
|
|
2222
|
+
|
|
2223
|
+
|
|
2224
|
+
|
|
2142
2225
|
|
|
2143
2226
|
|
|
2144
2227
|
|
|
@@ -2181,6 +2264,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2181
2264
|
|
|
2182
2265
|
|
|
2183
2266
|
|
|
2267
|
+
|
|
2268
|
+
|
|
2269
|
+
|
|
2270
|
+
|
|
2184
2271
|
|
|
2185
2272
|
|
|
2186
2273
|
|
|
@@ -2244,6 +2331,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2244
2331
|
|
|
2245
2332
|
|
|
2246
2333
|
|
|
2334
|
+
|
|
2335
|
+
|
|
2336
|
+
|
|
2337
|
+
|
|
2247
2338
|
|
|
2248
2339
|
|
|
2249
2340
|
|
|
@@ -2260,22 +2351,66 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2260
2351
|
this.setMany(anotherTree, []);
|
|
2261
2352
|
}
|
|
2262
2353
|
/**
|
|
2263
|
-
*
|
|
2264
|
-
* @remarks Time O(N)
|
|
2354
|
+
* Deletes a node from the tree (internal, returns balancing metadata).
|
|
2355
|
+
* @remarks Time O(N) — O(N) to find the node + O(H) for predecessor swap. Space O(1). BST/Red-Black Tree/AVL Tree subclasses override to O(log N).
|
|
2356
|
+
* @internal Used by AVL/BST subclasses that need balancing metadata after deletion.
|
|
2265
2357
|
*
|
|
2266
|
-
* @param
|
|
2267
|
-
* @
|
|
2358
|
+
* @param keyNodeEntryRawOrPredicate - The node to delete.
|
|
2359
|
+
* @returns An array containing deletion results with balancing metadata.
|
|
2268
2360
|
*/
|
|
2269
|
-
|
|
2270
|
-
|
|
2271
|
-
this.
|
|
2361
|
+
_deleteInternal(keyNodeEntryRawOrPredicate) {
|
|
2362
|
+
const deletedResult = [];
|
|
2363
|
+
if (!this._root) return deletedResult;
|
|
2364
|
+
const curr = this.getNode(keyNodeEntryRawOrPredicate);
|
|
2365
|
+
if (!curr) return deletedResult;
|
|
2366
|
+
const parent = curr == null ? void 0 : curr.parent;
|
|
2367
|
+
let needBalanced;
|
|
2368
|
+
let orgCurrent = curr;
|
|
2369
|
+
if (!curr.left && !curr.right && !parent) {
|
|
2370
|
+
this._setRoot(void 0);
|
|
2371
|
+
} else if (curr.left) {
|
|
2372
|
+
const leftSubTreeRightMost = this.getRightMost((node) => node, curr.left);
|
|
2373
|
+
if (leftSubTreeRightMost) {
|
|
2374
|
+
const parentOfLeftSubTreeMax = leftSubTreeRightMost.parent;
|
|
2375
|
+
orgCurrent = this._swapProperties(curr, leftSubTreeRightMost);
|
|
2376
|
+
if (this._isMapMode) {
|
|
2377
|
+
this._store.set(curr.key, curr);
|
|
2378
|
+
this._store.set(leftSubTreeRightMost.key, leftSubTreeRightMost);
|
|
2379
|
+
}
|
|
2380
|
+
if (parentOfLeftSubTreeMax) {
|
|
2381
|
+
if (parentOfLeftSubTreeMax.right === leftSubTreeRightMost)
|
|
2382
|
+
parentOfLeftSubTreeMax.right = leftSubTreeRightMost.left;
|
|
2383
|
+
else parentOfLeftSubTreeMax.left = leftSubTreeRightMost.left;
|
|
2384
|
+
needBalanced = parentOfLeftSubTreeMax;
|
|
2385
|
+
}
|
|
2386
|
+
}
|
|
2387
|
+
} else if (parent) {
|
|
2388
|
+
const { familyPosition: fp } = curr;
|
|
2389
|
+
if (fp === "LEFT" || fp === "ROOT_LEFT") {
|
|
2390
|
+
parent.left = curr.right;
|
|
2391
|
+
} else if (fp === "RIGHT" || fp === "ROOT_RIGHT") {
|
|
2392
|
+
parent.right = curr.right;
|
|
2393
|
+
}
|
|
2394
|
+
needBalanced = parent;
|
|
2395
|
+
} else {
|
|
2396
|
+
this._setRoot(curr.right);
|
|
2397
|
+
curr.right = void 0;
|
|
2398
|
+
}
|
|
2399
|
+
this._size = this._size - 1;
|
|
2400
|
+
deletedResult.push({ deleted: orgCurrent, needBalanced });
|
|
2401
|
+
if (this._isMapMode && orgCurrent) this._store.delete(orgCurrent.key);
|
|
2402
|
+
return deletedResult;
|
|
2272
2403
|
}
|
|
2273
2404
|
/**
|
|
2274
2405
|
* Deletes a node from the tree.
|
|
2275
|
-
* @remarks Time O(
|
|
2406
|
+
* @remarks Time O(N) — O(N) to find the node + O(H) for predecessor swap. Space O(1). BST/Red-Black Tree/AVL Tree subclasses override to O(log N).
|
|
2276
2407
|
*
|
|
2277
2408
|
* @param keyNodeEntryRawOrPredicate - The node to delete.
|
|
2278
|
-
* @returns
|
|
2409
|
+
* @returns True if the node was found and deleted, false otherwise.
|
|
2410
|
+
|
|
2411
|
+
|
|
2412
|
+
|
|
2413
|
+
|
|
2279
2414
|
|
|
2280
2415
|
|
|
2281
2416
|
|
|
@@ -2319,51 +2454,11 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2319
2454
|
* console.log(tree.size); // 4;
|
|
2320
2455
|
*/
|
|
2321
2456
|
delete(keyNodeEntryRawOrPredicate) {
|
|
2322
|
-
|
|
2323
|
-
if (!this._root) return deletedResult;
|
|
2324
|
-
const curr = this.getNode(keyNodeEntryRawOrPredicate);
|
|
2325
|
-
if (!curr) return deletedResult;
|
|
2326
|
-
const parent = curr == null ? void 0 : curr.parent;
|
|
2327
|
-
let needBalanced;
|
|
2328
|
-
let orgCurrent = curr;
|
|
2329
|
-
if (!curr.left && !curr.right && !parent) {
|
|
2330
|
-
this._setRoot(void 0);
|
|
2331
|
-
} else if (curr.left) {
|
|
2332
|
-
const leftSubTreeRightMost = this.getRightMost((node) => node, curr.left);
|
|
2333
|
-
if (leftSubTreeRightMost) {
|
|
2334
|
-
const parentOfLeftSubTreeMax = leftSubTreeRightMost.parent;
|
|
2335
|
-
orgCurrent = this._swapProperties(curr, leftSubTreeRightMost);
|
|
2336
|
-
if (this._isMapMode) {
|
|
2337
|
-
this._store.set(curr.key, curr);
|
|
2338
|
-
this._store.set(leftSubTreeRightMost.key, leftSubTreeRightMost);
|
|
2339
|
-
}
|
|
2340
|
-
if (parentOfLeftSubTreeMax) {
|
|
2341
|
-
if (parentOfLeftSubTreeMax.right === leftSubTreeRightMost)
|
|
2342
|
-
parentOfLeftSubTreeMax.right = leftSubTreeRightMost.left;
|
|
2343
|
-
else parentOfLeftSubTreeMax.left = leftSubTreeRightMost.left;
|
|
2344
|
-
needBalanced = parentOfLeftSubTreeMax;
|
|
2345
|
-
}
|
|
2346
|
-
}
|
|
2347
|
-
} else if (parent) {
|
|
2348
|
-
const { familyPosition: fp } = curr;
|
|
2349
|
-
if (fp === "LEFT" || fp === "ROOT_LEFT") {
|
|
2350
|
-
parent.left = curr.right;
|
|
2351
|
-
} else if (fp === "RIGHT" || fp === "ROOT_RIGHT") {
|
|
2352
|
-
parent.right = curr.right;
|
|
2353
|
-
}
|
|
2354
|
-
needBalanced = parent;
|
|
2355
|
-
} else {
|
|
2356
|
-
this._setRoot(curr.right);
|
|
2357
|
-
curr.right = void 0;
|
|
2358
|
-
}
|
|
2359
|
-
this._size = this._size - 1;
|
|
2360
|
-
deletedResult.push({ deleted: orgCurrent, needBalanced });
|
|
2361
|
-
if (this._isMapMode && orgCurrent) this._store.delete(orgCurrent.key);
|
|
2362
|
-
return deletedResult;
|
|
2457
|
+
return this._deleteInternal(keyNodeEntryRawOrPredicate).length > 0;
|
|
2363
2458
|
}
|
|
2364
2459
|
/**
|
|
2365
2460
|
* Searches the tree for nodes matching a predicate.
|
|
2366
|
-
* @remarks Time O(
|
|
2461
|
+
* @remarks Time O(N) — full DFS scan; may visit every node. Space O(H) for call/explicit stack (O(N) worst-case). BST subclasses with key search override to O(log N).
|
|
2367
2462
|
*
|
|
2368
2463
|
* @template C - The type of the callback function.
|
|
2369
2464
|
* @param keyNodeEntryOrPredicate - The key, node, entry, or predicate function to search for.
|
|
@@ -2412,7 +2507,7 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2412
2507
|
}
|
|
2413
2508
|
/**
|
|
2414
2509
|
* Gets the first node matching a predicate.
|
|
2415
|
-
* @remarks Time O(
|
|
2510
|
+
* @remarks Time O(N) via `search`. Space O(H) or O(N). BST/Red-Black Tree/AVL Tree subclasses override to O(log N) for key lookups.
|
|
2416
2511
|
*
|
|
2417
2512
|
* @param keyNodeEntryOrPredicate - The key, node, entry, or predicate function to search for.
|
|
2418
2513
|
* @param [startNode=this._root] - The node to start the search from.
|
|
@@ -2446,6 +2541,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2446
2541
|
|
|
2447
2542
|
|
|
2448
2543
|
|
|
2544
|
+
|
|
2545
|
+
|
|
2546
|
+
|
|
2547
|
+
|
|
2449
2548
|
|
|
2450
2549
|
|
|
2451
2550
|
|
|
@@ -2468,7 +2567,7 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2468
2567
|
}
|
|
2469
2568
|
/**
|
|
2470
2569
|
* Gets the value associated with a key.
|
|
2471
|
-
* @remarks Time O(
|
|
2570
|
+
* @remarks Time O(1) in Map mode, O(N) otherwise (via `getNode`). Space O(1) in Map mode, O(H) or O(N) otherwise. BST subclasses override non-Map-mode to O(log N).
|
|
2472
2571
|
*
|
|
2473
2572
|
* @param keyNodeEntryOrPredicate - The key, node, or entry to get the value for.
|
|
2474
2573
|
* @param [startNode=this._root] - The node to start searching from (if not in Map mode).
|
|
@@ -2504,6 +2603,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2504
2603
|
|
|
2505
2604
|
|
|
2506
2605
|
|
|
2606
|
+
|
|
2607
|
+
|
|
2608
|
+
|
|
2609
|
+
|
|
2507
2610
|
|
|
2508
2611
|
|
|
2509
2612
|
|
|
@@ -2565,6 +2668,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2565
2668
|
|
|
2566
2669
|
|
|
2567
2670
|
|
|
2671
|
+
|
|
2672
|
+
|
|
2673
|
+
|
|
2674
|
+
|
|
2568
2675
|
|
|
2569
2676
|
|
|
2570
2677
|
|
|
@@ -2613,6 +2720,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2613
2720
|
|
|
2614
2721
|
|
|
2615
2722
|
|
|
2723
|
+
|
|
2724
|
+
|
|
2725
|
+
|
|
2726
|
+
|
|
2616
2727
|
|
|
2617
2728
|
|
|
2618
2729
|
|
|
@@ -2670,6 +2781,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2670
2781
|
|
|
2671
2782
|
|
|
2672
2783
|
|
|
2784
|
+
|
|
2785
|
+
|
|
2786
|
+
|
|
2787
|
+
|
|
2673
2788
|
|
|
2674
2789
|
|
|
2675
2790
|
|
|
@@ -2754,6 +2869,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2754
2869
|
|
|
2755
2870
|
|
|
2756
2871
|
|
|
2872
|
+
|
|
2873
|
+
|
|
2874
|
+
|
|
2875
|
+
|
|
2757
2876
|
|
|
2758
2877
|
|
|
2759
2878
|
|
|
@@ -2815,6 +2934,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
2815
2934
|
|
|
2816
2935
|
|
|
2817
2936
|
|
|
2937
|
+
|
|
2938
|
+
|
|
2939
|
+
|
|
2940
|
+
|
|
2818
2941
|
|
|
2819
2942
|
|
|
2820
2943
|
|
|
@@ -3292,6 +3415,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
3292
3415
|
|
|
3293
3416
|
|
|
3294
3417
|
|
|
3418
|
+
|
|
3419
|
+
|
|
3420
|
+
|
|
3421
|
+
|
|
3295
3422
|
|
|
3296
3423
|
|
|
3297
3424
|
|
|
@@ -3344,6 +3471,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
3344
3471
|
|
|
3345
3472
|
|
|
3346
3473
|
|
|
3474
|
+
|
|
3475
|
+
|
|
3476
|
+
|
|
3477
|
+
|
|
3347
3478
|
|
|
3348
3479
|
|
|
3349
3480
|
|
|
@@ -3400,6 +3531,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
3400
3531
|
|
|
3401
3532
|
|
|
3402
3533
|
|
|
3534
|
+
|
|
3535
|
+
|
|
3536
|
+
|
|
3537
|
+
|
|
3403
3538
|
|
|
3404
3539
|
|
|
3405
3540
|
|
|
@@ -3481,6 +3616,10 @@ var _BinaryTree = class _BinaryTree extends IterableEntryBase {
|
|
|
3481
3616
|
|
|
3482
3617
|
|
|
3483
3618
|
|
|
3619
|
+
|
|
3620
|
+
|
|
3621
|
+
|
|
3622
|
+
|
|
3484
3623
|
|
|
3485
3624
|
|
|
3486
3625
|
|