data-structure-typed 1.49.5 → 1.49.7

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 (222) hide show
  1. package/CHANGELOG.md +1 -1
  2. package/README.md +17 -23
  3. package/README_zh-CN.md +2 -0
  4. package/benchmark/report.html +14 -23
  5. package/benchmark/report.json +158 -251
  6. package/dist/cjs/data-structures/binary-tree/avl-tree.d.ts +53 -48
  7. package/dist/cjs/data-structures/binary-tree/avl-tree.js +55 -49
  8. package/dist/cjs/data-structures/binary-tree/avl-tree.js.map +1 -1
  9. package/dist/cjs/data-structures/binary-tree/binary-tree.d.ts +153 -130
  10. package/dist/cjs/data-structures/binary-tree/binary-tree.js +194 -153
  11. package/dist/cjs/data-structures/binary-tree/binary-tree.js.map +1 -1
  12. package/dist/cjs/data-structures/binary-tree/bst.d.ts +83 -71
  13. package/dist/cjs/data-structures/binary-tree/bst.js +114 -91
  14. package/dist/cjs/data-structures/binary-tree/bst.js.map +1 -1
  15. package/dist/cjs/data-structures/binary-tree/rb-tree.d.ts +37 -35
  16. package/dist/cjs/data-structures/binary-tree/rb-tree.js +62 -59
  17. package/dist/cjs/data-structures/binary-tree/rb-tree.js.map +1 -1
  18. package/dist/cjs/data-structures/binary-tree/tree-multimap.d.ts +46 -39
  19. package/dist/cjs/data-structures/binary-tree/tree-multimap.js +58 -51
  20. package/dist/cjs/data-structures/binary-tree/tree-multimap.js.map +1 -1
  21. package/dist/cjs/data-structures/hash/hash-map.d.ts +24 -27
  22. package/dist/cjs/data-structures/hash/hash-map.js +35 -35
  23. package/dist/cjs/data-structures/hash/hash-map.js.map +1 -1
  24. package/dist/cjs/data-structures/hash/index.d.ts +0 -1
  25. package/dist/cjs/data-structures/hash/index.js +0 -1
  26. package/dist/cjs/data-structures/hash/index.js.map +1 -1
  27. package/dist/cjs/data-structures/heap/heap.d.ts +2 -1
  28. package/dist/cjs/data-structures/heap/heap.js +13 -13
  29. package/dist/cjs/data-structures/heap/heap.js.map +1 -1
  30. package/dist/cjs/data-structures/heap/max-heap.js +1 -1
  31. package/dist/cjs/data-structures/heap/max-heap.js.map +1 -1
  32. package/dist/cjs/data-structures/heap/min-heap.js +1 -1
  33. package/dist/cjs/data-structures/heap/min-heap.js.map +1 -1
  34. package/dist/cjs/data-structures/linked-list/doubly-linked-list.js +1 -1
  35. package/dist/cjs/data-structures/linked-list/doubly-linked-list.js.map +1 -1
  36. package/dist/cjs/data-structures/linked-list/singly-linked-list.js +1 -3
  37. package/dist/cjs/data-structures/linked-list/singly-linked-list.js.map +1 -1
  38. package/dist/cjs/data-structures/linked-list/skip-linked-list.d.ts +2 -8
  39. package/dist/cjs/data-structures/linked-list/skip-linked-list.js +15 -18
  40. package/dist/cjs/data-structures/linked-list/skip-linked-list.js.map +1 -1
  41. package/dist/cjs/data-structures/matrix/matrix.d.ts +2 -7
  42. package/dist/cjs/data-structures/matrix/matrix.js +0 -7
  43. package/dist/cjs/data-structures/matrix/matrix.js.map +1 -1
  44. package/dist/cjs/data-structures/priority-queue/max-priority-queue.js +1 -1
  45. package/dist/cjs/data-structures/priority-queue/max-priority-queue.js.map +1 -1
  46. package/dist/cjs/data-structures/priority-queue/min-priority-queue.js +1 -1
  47. package/dist/cjs/data-structures/priority-queue/min-priority-queue.js.map +1 -1
  48. package/dist/cjs/data-structures/priority-queue/priority-queue.js +1 -1
  49. package/dist/cjs/data-structures/priority-queue/priority-queue.js.map +1 -1
  50. package/dist/cjs/data-structures/queue/deque.d.ts +2 -11
  51. package/dist/cjs/data-structures/queue/deque.js +9 -13
  52. package/dist/cjs/data-structures/queue/deque.js.map +1 -1
  53. package/dist/cjs/data-structures/queue/queue.d.ts +13 -13
  54. package/dist/cjs/data-structures/queue/queue.js +29 -25
  55. package/dist/cjs/data-structures/queue/queue.js.map +1 -1
  56. package/dist/cjs/data-structures/stack/stack.js +2 -3
  57. package/dist/cjs/data-structures/stack/stack.js.map +1 -1
  58. package/dist/cjs/data-structures/trie/trie.d.ts +2 -2
  59. package/dist/cjs/data-structures/trie/trie.js +9 -5
  60. package/dist/cjs/data-structures/trie/trie.js.map +1 -1
  61. package/dist/cjs/interfaces/binary-tree.d.ts +3 -3
  62. package/dist/cjs/types/common.d.ts +3 -3
  63. package/dist/cjs/types/common.js +2 -2
  64. package/dist/cjs/types/common.js.map +1 -1
  65. package/dist/cjs/types/data-structures/binary-tree/binary-tree.d.ts +2 -2
  66. package/dist/cjs/types/data-structures/binary-tree/bst.d.ts +1 -1
  67. package/dist/cjs/types/data-structures/binary-tree/tree-multimap.d.ts +1 -1
  68. package/dist/cjs/types/data-structures/hash/hash-map.d.ts +5 -2
  69. package/dist/cjs/types/data-structures/hash/index.d.ts +0 -1
  70. package/dist/cjs/types/data-structures/hash/index.js +0 -1
  71. package/dist/cjs/types/data-structures/hash/index.js.map +1 -1
  72. package/dist/cjs/types/data-structures/heap/heap.d.ts +1 -1
  73. package/dist/cjs/types/data-structures/linked-list/index.d.ts +1 -0
  74. package/dist/cjs/types/data-structures/linked-list/index.js +1 -0
  75. package/dist/cjs/types/data-structures/linked-list/index.js.map +1 -1
  76. package/dist/cjs/types/data-structures/linked-list/skip-linked-list.d.ts +4 -1
  77. package/dist/cjs/types/data-structures/matrix/index.d.ts +1 -0
  78. package/dist/cjs/types/data-structures/matrix/index.js +1 -0
  79. package/dist/cjs/types/data-structures/matrix/index.js.map +1 -1
  80. package/dist/cjs/types/data-structures/matrix/matrix.d.ts +7 -1
  81. package/dist/cjs/types/data-structures/queue/deque.d.ts +3 -1
  82. package/dist/cjs/types/data-structures/trie/trie.d.ts +3 -1
  83. package/dist/mjs/data-structures/binary-tree/avl-tree.d.ts +53 -48
  84. package/dist/mjs/data-structures/binary-tree/avl-tree.js +55 -49
  85. package/dist/mjs/data-structures/binary-tree/binary-tree.d.ts +153 -130
  86. package/dist/mjs/data-structures/binary-tree/binary-tree.js +194 -153
  87. package/dist/mjs/data-structures/binary-tree/bst.d.ts +83 -71
  88. package/dist/mjs/data-structures/binary-tree/bst.js +114 -91
  89. package/dist/mjs/data-structures/binary-tree/rb-tree.d.ts +37 -35
  90. package/dist/mjs/data-structures/binary-tree/rb-tree.js +62 -59
  91. package/dist/mjs/data-structures/binary-tree/tree-multimap.d.ts +46 -39
  92. package/dist/mjs/data-structures/binary-tree/tree-multimap.js +58 -51
  93. package/dist/mjs/data-structures/hash/hash-map.d.ts +24 -27
  94. package/dist/mjs/data-structures/hash/hash-map.js +35 -37
  95. package/dist/mjs/data-structures/hash/index.d.ts +0 -1
  96. package/dist/mjs/data-structures/hash/index.js +0 -1
  97. package/dist/mjs/data-structures/heap/heap.d.ts +2 -1
  98. package/dist/mjs/data-structures/heap/heap.js +19 -20
  99. package/dist/mjs/data-structures/heap/max-heap.js +1 -1
  100. package/dist/mjs/data-structures/heap/min-heap.js +1 -1
  101. package/dist/mjs/data-structures/linked-list/doubly-linked-list.js +1 -1
  102. package/dist/mjs/data-structures/linked-list/singly-linked-list.js +2 -5
  103. package/dist/mjs/data-structures/linked-list/skip-linked-list.d.ts +2 -8
  104. package/dist/mjs/data-structures/linked-list/skip-linked-list.js +16 -23
  105. package/dist/mjs/data-structures/matrix/matrix.d.ts +2 -7
  106. package/dist/mjs/data-structures/matrix/matrix.js +0 -7
  107. package/dist/mjs/data-structures/priority-queue/max-priority-queue.js +1 -1
  108. package/dist/mjs/data-structures/priority-queue/min-priority-queue.js +1 -1
  109. package/dist/mjs/data-structures/priority-queue/priority-queue.js +1 -1
  110. package/dist/mjs/data-structures/queue/deque.d.ts +2 -11
  111. package/dist/mjs/data-structures/queue/deque.js +9 -14
  112. package/dist/mjs/data-structures/queue/queue.d.ts +13 -13
  113. package/dist/mjs/data-structures/queue/queue.js +30 -28
  114. package/dist/mjs/data-structures/stack/stack.js +3 -5
  115. package/dist/mjs/data-structures/trie/trie.d.ts +2 -2
  116. package/dist/mjs/data-structures/trie/trie.js +10 -9
  117. package/dist/mjs/interfaces/binary-tree.d.ts +3 -3
  118. package/dist/mjs/types/common.d.ts +3 -3
  119. package/dist/mjs/types/common.js +2 -2
  120. package/dist/mjs/types/data-structures/binary-tree/binary-tree.d.ts +2 -2
  121. package/dist/mjs/types/data-structures/binary-tree/bst.d.ts +1 -1
  122. package/dist/mjs/types/data-structures/binary-tree/tree-multimap.d.ts +1 -1
  123. package/dist/mjs/types/data-structures/hash/hash-map.d.ts +5 -2
  124. package/dist/mjs/types/data-structures/hash/index.d.ts +0 -1
  125. package/dist/mjs/types/data-structures/hash/index.js +0 -1
  126. package/dist/mjs/types/data-structures/heap/heap.d.ts +1 -1
  127. package/dist/mjs/types/data-structures/linked-list/index.d.ts +1 -0
  128. package/dist/mjs/types/data-structures/linked-list/index.js +1 -0
  129. package/dist/mjs/types/data-structures/linked-list/skip-linked-list.d.ts +4 -1
  130. package/dist/mjs/types/data-structures/matrix/index.d.ts +1 -0
  131. package/dist/mjs/types/data-structures/matrix/index.js +1 -0
  132. package/dist/mjs/types/data-structures/matrix/matrix.d.ts +7 -1
  133. package/dist/mjs/types/data-structures/queue/deque.d.ts +3 -1
  134. package/dist/mjs/types/data-structures/trie/trie.d.ts +3 -1
  135. package/dist/umd/data-structure-typed.js +620 -823
  136. package/dist/umd/data-structure-typed.min.js +2 -2
  137. package/dist/umd/data-structure-typed.min.js.map +1 -1
  138. package/package.json +1 -1
  139. package/src/data-structures/binary-tree/avl-tree.ts +58 -53
  140. package/src/data-structures/binary-tree/binary-tree.ts +255 -211
  141. package/src/data-structures/binary-tree/bst.ts +126 -107
  142. package/src/data-structures/binary-tree/rb-tree.ts +66 -64
  143. package/src/data-structures/binary-tree/tree-multimap.ts +62 -56
  144. package/src/data-structures/hash/hash-map.ts +46 -50
  145. package/src/data-structures/hash/index.ts +0 -1
  146. package/src/data-structures/heap/heap.ts +20 -19
  147. package/src/data-structures/heap/max-heap.ts +1 -1
  148. package/src/data-structures/heap/min-heap.ts +1 -1
  149. package/src/data-structures/linked-list/doubly-linked-list.ts +1 -1
  150. package/src/data-structures/linked-list/singly-linked-list.ts +2 -5
  151. package/src/data-structures/linked-list/skip-linked-list.ts +15 -16
  152. package/src/data-structures/matrix/matrix.ts +2 -10
  153. package/src/data-structures/priority-queue/max-priority-queue.ts +1 -1
  154. package/src/data-structures/priority-queue/min-priority-queue.ts +1 -1
  155. package/src/data-structures/priority-queue/priority-queue.ts +1 -1
  156. package/src/data-structures/queue/deque.ts +11 -15
  157. package/src/data-structures/queue/queue.ts +29 -28
  158. package/src/data-structures/stack/stack.ts +3 -6
  159. package/src/data-structures/trie/trie.ts +10 -11
  160. package/src/interfaces/binary-tree.ts +3 -3
  161. package/src/types/common.ts +3 -3
  162. package/src/types/data-structures/binary-tree/binary-tree.ts +2 -2
  163. package/src/types/data-structures/binary-tree/bst.ts +1 -1
  164. package/src/types/data-structures/binary-tree/tree-multimap.ts +1 -1
  165. package/src/types/data-structures/hash/hash-map.ts +6 -2
  166. package/src/types/data-structures/hash/index.ts +0 -1
  167. package/src/types/data-structures/heap/heap.ts +1 -1
  168. package/src/types/data-structures/linked-list/index.ts +1 -0
  169. package/src/types/data-structures/linked-list/skip-linked-list.ts +1 -1
  170. package/src/types/data-structures/matrix/index.ts +1 -0
  171. package/src/types/data-structures/matrix/matrix.ts +7 -1
  172. package/src/types/data-structures/queue/deque.ts +1 -1
  173. package/src/types/data-structures/trie/trie.ts +1 -1
  174. package/test/performance/data-structures/binary-tree/avl-tree.test.ts +4 -12
  175. package/test/performance/data-structures/binary-tree/binary-tree-overall.test.ts +37 -0
  176. package/test/performance/data-structures/binary-tree/binary-tree.test.ts +6 -16
  177. package/test/performance/data-structures/binary-tree/bst.test.ts +5 -13
  178. package/test/performance/data-structures/binary-tree/rb-tree.test.ts +5 -15
  179. package/test/performance/data-structures/comparison/comparison.test.ts +13 -36
  180. package/test/performance/data-structures/graph/directed-graph.test.ts +3 -14
  181. package/test/performance/data-structures/hash/hash-map.test.ts +11 -34
  182. package/test/performance/data-structures/heap/heap.test.ts +5 -18
  183. package/test/performance/data-structures/linked-list/doubly-linked-list.test.ts +0 -1
  184. package/test/performance/data-structures/linked-list/singly-linked-list.test.ts +0 -2
  185. package/test/performance/data-structures/priority-queue/max-priority-queue.test.ts +2 -4
  186. package/test/performance/data-structures/priority-queue/priority-queue.test.ts +4 -14
  187. package/test/performance/data-structures/queue/queue.test.ts +8 -25
  188. package/test/performance/data-structures/stack/stack.test.ts +6 -18
  189. package/test/performance/data-structures/trie/trie.test.ts +2 -6
  190. package/test/unit/data-structures/binary-tree/binary-tree.test.ts +6 -5
  191. package/test/unit/data-structures/binary-tree/bst.test.ts +17 -1
  192. package/test/unit/data-structures/linked-list/skip-list.test.ts +1 -1
  193. package/test/unit/data-structures/queue/deque.test.ts +5 -5
  194. package/test/unit/data-structures/trie/trie.test.ts +1 -1
  195. package/dist/cjs/data-structures/hash/hash-table.d.ts +0 -108
  196. package/dist/cjs/data-structures/hash/hash-table.js +0 -282
  197. package/dist/cjs/data-structures/hash/hash-table.js.map +0 -1
  198. package/dist/cjs/types/data-structures/hash/hash-table.d.ts +0 -1
  199. package/dist/cjs/types/data-structures/hash/hash-table.js +0 -3
  200. package/dist/cjs/types/data-structures/hash/hash-table.js.map +0 -1
  201. package/dist/cjs/types/data-structures/matrix/matrix2d.d.ts +0 -1
  202. package/dist/cjs/types/data-structures/matrix/matrix2d.js +0 -3
  203. package/dist/cjs/types/data-structures/matrix/matrix2d.js.map +0 -1
  204. package/dist/cjs/types/data-structures/matrix/vector2d.d.ts +0 -1
  205. package/dist/cjs/types/data-structures/matrix/vector2d.js +0 -3
  206. package/dist/cjs/types/data-structures/matrix/vector2d.js.map +0 -1
  207. package/dist/mjs/data-structures/hash/hash-table.d.ts +0 -108
  208. package/dist/mjs/data-structures/hash/hash-table.js +0 -283
  209. package/dist/mjs/types/data-structures/hash/hash-table.d.ts +0 -1
  210. package/dist/mjs/types/data-structures/hash/hash-table.js +0 -1
  211. package/dist/mjs/types/data-structures/matrix/matrix2d.d.ts +0 -1
  212. package/dist/mjs/types/data-structures/matrix/matrix2d.js +0 -1
  213. package/dist/mjs/types/data-structures/matrix/vector2d.d.ts +0 -1
  214. package/dist/mjs/types/data-structures/matrix/vector2d.js +0 -1
  215. package/src/data-structures/hash/hash-table.ts +0 -318
  216. package/src/types/data-structures/hash/hash-table.ts +0 -1
  217. package/src/types/data-structures/matrix/matrix2d.ts +0 -1
  218. package/src/types/data-structures/matrix/vector2d.ts +0 -1
  219. package/test/performance/data-structures/binary-tree/overall.test.ts +0 -0
  220. package/test/performance/data-structures/matrix/matrix2d.test.ts +0 -0
  221. package/test/performance/data-structures/matrix/vector2d.test.ts +0 -0
  222. package/test/unit/data-structures/hash/hash-table.test.ts +0 -238
@@ -3,226 +3,144 @@
3
3
  "benchmarks": [
4
4
  {
5
5
  "test name": "10,000 add randomly",
6
- "time taken (ms)": "48.42",
7
- "executions per sec": "20.65",
8
- "sample deviation": "0.00"
6
+ "time taken (ms)": "126.82",
7
+ "executions per sec": "7.88",
8
+ "sample deviation": "0.01"
9
9
  },
10
10
  {
11
11
  "test name": "10,000 add & delete randomly",
12
- "time taken (ms)": "107.72",
13
- "executions per sec": "9.28",
14
- "sample deviation": "0.02"
12
+ "time taken (ms)": "186.36",
13
+ "executions per sec": "5.37",
14
+ "sample deviation": "0.00"
15
15
  },
16
16
  {
17
17
  "test name": "10,000 addMany",
18
- "time taken (ms)": "55.40",
19
- "executions per sec": "18.05",
20
- "sample deviation": "6.22e-4"
18
+ "time taken (ms)": "133.15",
19
+ "executions per sec": "7.51",
20
+ "sample deviation": "0.00"
21
21
  },
22
22
  {
23
23
  "test name": "10,000 get",
24
- "time taken (ms)": "53.89",
25
- "executions per sec": "18.56",
26
- "sample deviation": "0.02"
24
+ "time taken (ms)": "50.65",
25
+ "executions per sec": "19.74",
26
+ "sample deviation": "5.59e-4"
27
27
  }
28
28
  ],
29
29
  "testName": "avl-tree"
30
30
  },
31
- "binary-tree": {
31
+ "binary-tree-overall": {
32
32
  "benchmarks": [
33
33
  {
34
- "test name": "1,000 add randomly",
35
- "time taken (ms)": "17.75",
36
- "executions per sec": "56.35",
37
- "sample deviation": "2.23e-4"
34
+ "test name": "10,000 RBTree add",
35
+ "time taken (ms)": "6.12",
36
+ "executions per sec": "163.48",
37
+ "sample deviation": "1.94e-4"
38
38
  },
39
39
  {
40
- "test name": "1,000 add & delete randomly",
41
- "time taken (ms)": "25.58",
42
- "executions per sec": "39.10",
43
- "sample deviation": "0.01"
40
+ "test name": "10,000 RBTree add & delete randomly",
41
+ "time taken (ms)": "15.46",
42
+ "executions per sec": "64.70",
43
+ "sample deviation": "3.64e-4"
44
44
  },
45
45
  {
46
- "test name": "1,000 addMany",
47
- "time taken (ms)": "19.65",
48
- "executions per sec": "50.89",
46
+ "test name": "10,000 RBTree get",
47
+ "time taken (ms)": "19.98",
48
+ "executions per sec": "50.06",
49
49
  "sample deviation": "0.00"
50
50
  },
51
51
  {
52
- "test name": "1,000 get",
53
- "time taken (ms)": "21.03",
54
- "executions per sec": "47.55",
55
- "sample deviation": "0.01"
56
- },
57
- {
58
- "test name": "1,000 has",
59
- "time taken (ms)": "19.81",
60
- "executions per sec": "50.48",
61
- "sample deviation": "0.01"
62
- },
63
- {
64
- "test name": "1,000 dfs",
65
- "time taken (ms)": "183.37",
66
- "executions per sec": "5.45",
67
- "sample deviation": "0.03"
68
- },
69
- {
70
- "test name": "1,000 bfs",
71
- "time taken (ms)": "65.61",
72
- "executions per sec": "15.24",
73
- "sample deviation": "0.02"
74
- },
75
- {
76
- "test name": "1,000 morris",
77
- "time taken (ms)": "231.00",
78
- "executions per sec": "4.33",
79
- "sample deviation": "0.06"
80
- }
81
- ],
82
- "testName": "binary-tree"
83
- },
84
- "bst": {
85
- "benchmarks": [
86
- {
87
- "test name": "10,000 add randomly",
88
- "time taken (ms)": "49.96",
89
- "executions per sec": "20.02",
90
- "sample deviation": "7.65e-4"
91
- },
92
- {
93
- "test name": "10,000 add & delete randomly",
94
- "time taken (ms)": "116.77",
95
- "executions per sec": "8.56",
52
+ "test name": "10,000 AVLTree add",
53
+ "time taken (ms)": "130.40",
54
+ "executions per sec": "7.67",
96
55
  "sample deviation": "0.02"
97
56
  },
98
57
  {
99
- "test name": "10,000 addMany",
100
- "time taken (ms)": "49.06",
101
- "executions per sec": "20.38",
58
+ "test name": "10,000 AVLTree add & delete randomly",
59
+ "time taken (ms)": "193.64",
60
+ "executions per sec": "5.16",
102
61
  "sample deviation": "0.01"
103
62
  },
104
63
  {
105
- "test name": "10,000 get",
106
- "time taken (ms)": "49.06",
107
- "executions per sec": "20.38",
108
- "sample deviation": "7.13e-4"
64
+ "test name": "10,000 AVLTree get",
65
+ "time taken (ms)": "0.99",
66
+ "executions per sec": "1005.44",
67
+ "sample deviation": "3.95e-5"
109
68
  }
110
69
  ],
111
- "testName": "bst"
70
+ "testName": "binary-tree-overall"
112
71
  },
113
72
  "rb-tree": {
114
73
  "benchmarks": [
115
74
  {
116
75
  "test name": "100,000 add",
117
- "time taken (ms)": "83.42",
118
- "executions per sec": "11.99",
119
- "sample deviation": "0.01"
76
+ "time taken (ms)": "90.72",
77
+ "executions per sec": "11.02",
78
+ "sample deviation": "0.03"
120
79
  },
121
80
  {
122
81
  "test name": "100,000 add & delete randomly",
123
- "time taken (ms)": "243.05",
124
- "executions per sec": "4.11",
125
- "sample deviation": "0.07"
82
+ "time taken (ms)": "228.77",
83
+ "executions per sec": "4.37",
84
+ "sample deviation": "0.02"
126
85
  },
127
86
  {
128
87
  "test name": "100,000 getNode",
129
- "time taken (ms)": "218.87",
130
- "executions per sec": "4.57",
131
- "sample deviation": "0.05"
88
+ "time taken (ms)": "192.25",
89
+ "executions per sec": "5.20",
90
+ "sample deviation": "5.16e-4"
132
91
  },
133
92
  {
134
93
  "test name": "100,000 add & iterator",
135
- "time taken (ms)": "124.22",
136
- "executions per sec": "8.05",
94
+ "time taken (ms)": "112.49",
95
+ "executions per sec": "8.89",
137
96
  "sample deviation": "0.01"
138
97
  }
139
98
  ],
140
99
  "testName": "rb-tree"
141
100
  },
142
- "comparison": {
143
- "benchmarks": [
144
- {
145
- "test name": "SRC PQ 10,000 add",
146
- "time taken (ms)": "0.15",
147
- "executions per sec": "6710.40",
148
- "sample deviation": "1.90e-5"
149
- },
150
- {
151
- "test name": "CJS PQ 10,000 add",
152
- "time taken (ms)": "0.16",
153
- "executions per sec": "6407.42",
154
- "sample deviation": "4.25e-5"
155
- },
156
- {
157
- "test name": "MJS PQ 10,000 add",
158
- "time taken (ms)": "0.62",
159
- "executions per sec": "1602.37",
160
- "sample deviation": "1.51e-4"
161
- },
162
- {
163
- "test name": "SRC PQ 10,000 add & poll",
164
- "time taken (ms)": "3.67",
165
- "executions per sec": "272.42",
166
- "sample deviation": "0.00"
167
- },
168
- {
169
- "test name": "CJS PQ 10,000 add & poll",
170
- "time taken (ms)": "3.95",
171
- "executions per sec": "252.90",
172
- "sample deviation": "0.00"
173
- },
174
- {
175
- "test name": "MJS PQ 10,000 add & poll",
176
- "time taken (ms)": "3.33",
177
- "executions per sec": "300.28",
178
- "sample deviation": "8.65e-5"
179
- }
180
- ],
181
- "testName": "comparison"
182
- },
183
101
  "directed-graph": {
184
102
  "benchmarks": [
185
103
  {
186
104
  "test name": "1,000 addVertex",
187
105
  "time taken (ms)": "0.11",
188
- "executions per sec": "8958.10",
189
- "sample deviation": "3.30e-5"
106
+ "executions per sec": "9250.94",
107
+ "sample deviation": "1.22e-5"
190
108
  },
191
109
  {
192
110
  "test name": "1,000 addEdge",
193
- "time taken (ms)": "6.37",
194
- "executions per sec": "156.98",
195
- "sample deviation": "1.96e-4"
111
+ "time taken (ms)": "6.35",
112
+ "executions per sec": "157.51",
113
+ "sample deviation": "2.88e-4"
196
114
  },
197
115
  {
198
116
  "test name": "1,000 getVertex",
199
117
  "time taken (ms)": "0.05",
200
- "executions per sec": "2.04e+4",
201
- "sample deviation": "8.22e-6"
118
+ "executions per sec": "2.06e+4",
119
+ "sample deviation": "8.69e-6"
202
120
  },
203
121
  {
204
122
  "test name": "1,000 getEdge",
205
- "time taken (ms)": "24.49",
206
- "executions per sec": "40.83",
123
+ "time taken (ms)": "23.02",
124
+ "executions per sec": "43.43",
207
125
  "sample deviation": "0.00"
208
126
  },
209
127
  {
210
128
  "test name": "tarjan",
211
- "time taken (ms)": "235.54",
212
- "executions per sec": "4.25",
213
- "sample deviation": "0.04"
129
+ "time taken (ms)": "213.85",
130
+ "executions per sec": "4.68",
131
+ "sample deviation": "0.01"
214
132
  },
215
133
  {
216
134
  "test name": "tarjan all",
217
- "time taken (ms)": "6766.74",
135
+ "time taken (ms)": "6674.11",
218
136
  "executions per sec": "0.15",
219
- "sample deviation": "0.32"
137
+ "sample deviation": "0.28"
220
138
  },
221
139
  {
222
140
  "test name": "topologicalSort",
223
- "time taken (ms)": "197.52",
224
- "executions per sec": "5.06",
225
- "sample deviation": "0.04"
141
+ "time taken (ms)": "179.09",
142
+ "executions per sec": "5.58",
143
+ "sample deviation": "0.00"
226
144
  }
227
145
  ],
228
146
  "testName": "directed-graph"
@@ -231,57 +149,57 @@
231
149
  "benchmarks": [
232
150
  {
233
151
  "test name": "1,000,000 set",
234
- "time taken (ms)": "117.82",
235
- "executions per sec": "8.49",
152
+ "time taken (ms)": "131.27",
153
+ "executions per sec": "7.62",
236
154
  "sample deviation": "0.05"
237
155
  },
238
156
  {
239
157
  "test name": "Native Map 1,000,000 set",
240
- "time taken (ms)": "220.92",
241
- "executions per sec": "4.53",
242
- "sample deviation": "0.03"
158
+ "time taken (ms)": "267.34",
159
+ "executions per sec": "3.74",
160
+ "sample deviation": "0.04"
243
161
  },
244
162
  {
245
163
  "test name": "Native Set 1,000,000 add",
246
- "time taken (ms)": "187.44",
247
- "executions per sec": "5.34",
248
- "sample deviation": "0.02"
164
+ "time taken (ms)": "207.03",
165
+ "executions per sec": "4.83",
166
+ "sample deviation": "0.06"
249
167
  },
250
168
  {
251
169
  "test name": "1,000,000 set & get",
252
- "time taken (ms)": "125.44",
253
- "executions per sec": "7.97",
254
- "sample deviation": "0.04"
170
+ "time taken (ms)": "132.19",
171
+ "executions per sec": "7.56",
172
+ "sample deviation": "0.03"
255
173
  },
256
174
  {
257
175
  "test name": "Native Map 1,000,000 set & get",
258
- "time taken (ms)": "300.10",
259
- "executions per sec": "3.33",
260
- "sample deviation": "0.06"
176
+ "time taken (ms)": "276.30",
177
+ "executions per sec": "3.62",
178
+ "sample deviation": "0.01"
261
179
  },
262
180
  {
263
181
  "test name": "Native Set 1,000,000 add & has",
264
- "time taken (ms)": "200.88",
265
- "executions per sec": "4.98",
182
+ "time taken (ms)": "187.74",
183
+ "executions per sec": "5.33",
266
184
  "sample deviation": "0.02"
267
185
  },
268
186
  {
269
187
  "test name": "1,000,000 ObjKey set & get",
270
- "time taken (ms)": "361.00",
271
- "executions per sec": "2.77",
272
- "sample deviation": "0.06"
188
+ "time taken (ms)": "336.39",
189
+ "executions per sec": "2.97",
190
+ "sample deviation": "0.03"
273
191
  },
274
192
  {
275
193
  "test name": "Native Map 1,000,000 ObjKey set & get",
276
- "time taken (ms)": "335.34",
277
- "executions per sec": "2.98",
194
+ "time taken (ms)": "394.47",
195
+ "executions per sec": "2.54",
278
196
  "sample deviation": "0.09"
279
197
  },
280
198
  {
281
199
  "test name": "Native Set 1,000,000 ObjKey add & has",
282
- "time taken (ms)": "261.28",
283
- "executions per sec": "3.83",
284
- "sample deviation": "0.07"
200
+ "time taken (ms)": "295.48",
201
+ "executions per sec": "3.38",
202
+ "sample deviation": "0.04"
285
203
  }
286
204
  ],
287
205
  "testName": "hash-map"
@@ -290,21 +208,21 @@
290
208
  "benchmarks": [
291
209
  {
292
210
  "test name": "100,000 add & poll",
293
- "time taken (ms)": "80.43",
294
- "executions per sec": "12.43",
295
- "sample deviation": "0.00"
211
+ "time taken (ms)": "24.18",
212
+ "executions per sec": "41.35",
213
+ "sample deviation": "6.43e-4"
296
214
  },
297
215
  {
298
216
  "test name": "100,000 add & dfs",
299
- "time taken (ms)": "36.95",
300
- "executions per sec": "27.07",
217
+ "time taken (ms)": "33.64",
218
+ "executions per sec": "29.72",
301
219
  "sample deviation": "0.00"
302
220
  },
303
221
  {
304
222
  "test name": "10,000 fib add & pop",
305
- "time taken (ms)": "386.63",
306
- "executions per sec": "2.59",
307
- "sample deviation": "0.05"
223
+ "time taken (ms)": "363.38",
224
+ "executions per sec": "2.75",
225
+ "sample deviation": "0.00"
308
226
  }
309
227
  ],
310
228
  "testName": "heap"
@@ -313,27 +231,27 @@
313
231
  "benchmarks": [
314
232
  {
315
233
  "test name": "1,000,000 push",
316
- "time taken (ms)": "235.15",
317
- "executions per sec": "4.25",
318
- "sample deviation": "0.07"
234
+ "time taken (ms)": "220.16",
235
+ "executions per sec": "4.54",
236
+ "sample deviation": "0.03"
319
237
  },
320
238
  {
321
239
  "test name": "1,000,000 unshift",
322
- "time taken (ms)": "245.36",
323
- "executions per sec": "4.08",
324
- "sample deviation": "0.08"
240
+ "time taken (ms)": "210.84",
241
+ "executions per sec": "4.74",
242
+ "sample deviation": "0.05"
325
243
  },
326
244
  {
327
245
  "test name": "1,000,000 unshift & shift",
328
- "time taken (ms)": "175.53",
329
- "executions per sec": "5.70",
330
- "sample deviation": "0.03"
246
+ "time taken (ms)": "189.59",
247
+ "executions per sec": "5.27",
248
+ "sample deviation": "0.07"
331
249
  },
332
250
  {
333
251
  "test name": "1,000,000 addBefore",
334
- "time taken (ms)": "319.21",
335
- "executions per sec": "3.13",
336
- "sample deviation": "0.06"
252
+ "time taken (ms)": "412.74",
253
+ "executions per sec": "2.42",
254
+ "sample deviation": "0.17"
337
255
  }
338
256
  ],
339
257
  "testName": "doubly-linked-list"
@@ -342,43 +260,32 @@
342
260
  "benchmarks": [
343
261
  {
344
262
  "test name": "1,000,000 push & shift",
345
- "time taken (ms)": "202.02",
346
- "executions per sec": "4.95",
347
- "sample deviation": "0.04"
263
+ "time taken (ms)": "252.06",
264
+ "executions per sec": "3.97",
265
+ "sample deviation": "0.09"
348
266
  },
349
267
  {
350
268
  "test name": "10,000 push & pop",
351
- "time taken (ms)": "228.77",
352
- "executions per sec": "4.37",
353
- "sample deviation": "0.04"
269
+ "time taken (ms)": "230.29",
270
+ "executions per sec": "4.34",
271
+ "sample deviation": "0.01"
354
272
  },
355
273
  {
356
274
  "test name": "10,000 addBefore",
357
- "time taken (ms)": "274.25",
358
- "executions per sec": "3.65",
359
- "sample deviation": "0.05"
275
+ "time taken (ms)": "261.57",
276
+ "executions per sec": "3.82",
277
+ "sample deviation": "0.01"
360
278
  }
361
279
  ],
362
280
  "testName": "singly-linked-list"
363
281
  },
364
- "max-priority-queue": {
365
- "benchmarks": [
366
- {
367
- "test name": "10,000 refill & poll",
368
- "time taken (ms)": "9.39",
369
- "executions per sec": "106.51",
370
- "sample deviation": "0.00"
371
- }
372
- ],
373
- "testName": "max-priority-queue"
374
- },
375
282
  "priority-queue": {
376
283
  "benchmarks": [
377
284
  {
378
285
  "test name": "100,000 add & poll",
379
- "time taken (ms)": "114.36",
380
- "executions per sec": "8.74",
381
- "sample deviation": "0.02"
286
+ "time taken (ms)": "75.71",
287
+ "executions per sec": "13.21",
288
+ "sample deviation": "8.95e-4"
382
289
  }
383
290
  ],
384
291
  "testName": "priority-queue"
@@ -387,39 +294,39 @@
387
294
  "benchmarks": [
388
295
  {
389
296
  "test name": "1,000,000 push",
390
- "time taken (ms)": "14.81",
391
- "executions per sec": "67.51",
392
- "sample deviation": "0.00"
297
+ "time taken (ms)": "25.18",
298
+ "executions per sec": "39.71",
299
+ "sample deviation": "0.01"
393
300
  },
394
301
  {
395
302
  "test name": "1,000,000 push & pop",
396
- "time taken (ms)": "25.34",
397
- "executions per sec": "39.47",
303
+ "time taken (ms)": "33.52",
304
+ "executions per sec": "29.83",
398
305
  "sample deviation": "0.01"
399
306
  },
400
307
  {
401
308
  "test name": "100,000 push & shift",
402
- "time taken (ms)": "2.49",
403
- "executions per sec": "400.86",
404
- "sample deviation": "7.97e-4"
309
+ "time taken (ms)": "3.61",
310
+ "executions per sec": "276.96",
311
+ "sample deviation": "5.50e-4"
405
312
  },
406
313
  {
407
314
  "test name": "Native Array 100,000 push & shift",
408
- "time taken (ms)": "2390.92",
409
- "executions per sec": "0.42",
410
- "sample deviation": "0.17"
315
+ "time taken (ms)": "2703.16",
316
+ "executions per sec": "0.37",
317
+ "sample deviation": "0.11"
411
318
  },
412
319
  {
413
320
  "test name": "100,000 unshift & shift",
414
- "time taken (ms)": "2.48",
415
- "executions per sec": "403.14",
416
- "sample deviation": "6.46e-4"
321
+ "time taken (ms)": "3.73",
322
+ "executions per sec": "268.14",
323
+ "sample deviation": "8.29e-4"
417
324
  },
418
325
  {
419
326
  "test name": "Native Array 100,000 unshift & shift",
420
- "time taken (ms)": "4462.41",
421
- "executions per sec": "0.22",
422
- "sample deviation": "0.34"
327
+ "time taken (ms)": "4767.61",
328
+ "executions per sec": "0.21",
329
+ "sample deviation": "0.40"
423
330
  }
424
331
  ],
425
332
  "testName": "deque"
@@ -428,27 +335,27 @@
428
335
  "benchmarks": [
429
336
  {
430
337
  "test name": "1,000,000 push",
431
- "time taken (ms)": "51.99",
432
- "executions per sec": "19.24",
433
- "sample deviation": "0.03"
338
+ "time taken (ms)": "50.56",
339
+ "executions per sec": "19.78",
340
+ "sample deviation": "0.01"
434
341
  },
435
342
  {
436
343
  "test name": "100,000 push & shift",
437
- "time taken (ms)": "5.23",
438
- "executions per sec": "191.34",
439
- "sample deviation": "7.00e-4"
344
+ "time taken (ms)": "5.99",
345
+ "executions per sec": "166.85",
346
+ "sample deviation": "0.00"
440
347
  },
441
348
  {
442
349
  "test name": "Native Array 100,000 push & shift",
443
- "time taken (ms)": "2400.96",
444
- "executions per sec": "0.42",
445
- "sample deviation": "0.28"
350
+ "time taken (ms)": "2962.43",
351
+ "executions per sec": "0.34",
352
+ "sample deviation": "0.29"
446
353
  },
447
354
  {
448
355
  "test name": "Native Array 100,000 push & pop",
449
- "time taken (ms)": "4.36",
450
- "executions per sec": "229.52",
451
- "sample deviation": "1.14e-4"
356
+ "time taken (ms)": "4.49",
357
+ "executions per sec": "222.69",
358
+ "sample deviation": "3.01e-4"
452
359
  }
453
360
  ],
454
361
  "testName": "queue"
@@ -457,14 +364,14 @@
457
364
  "benchmarks": [
458
365
  {
459
366
  "test name": "1,000,000 push",
460
- "time taken (ms)": "43.55",
461
- "executions per sec": "22.96",
462
- "sample deviation": "0.01"
367
+ "time taken (ms)": "59.68",
368
+ "executions per sec": "16.76",
369
+ "sample deviation": "0.03"
463
370
  },
464
371
  {
465
372
  "test name": "1,000,000 push & pop",
466
- "time taken (ms)": "55.29",
467
- "executions per sec": "18.09",
373
+ "time taken (ms)": "52.04",
374
+ "executions per sec": "19.22",
468
375
  "sample deviation": "0.01"
469
376
  }
470
377
  ],
@@ -474,15 +381,15 @@
474
381
  "benchmarks": [
475
382
  {
476
383
  "test name": "100,000 push",
477
- "time taken (ms)": "48.66",
478
- "executions per sec": "20.55",
384
+ "time taken (ms)": "47.70",
385
+ "executions per sec": "20.96",
479
386
  "sample deviation": "0.00"
480
387
  },
481
388
  {
482
389
  "test name": "100,000 getWords",
483
- "time taken (ms)": "95.09",
484
- "executions per sec": "10.52",
485
- "sample deviation": "0.01"
390
+ "time taken (ms)": "66.53",
391
+ "executions per sec": "15.03",
392
+ "sample deviation": "0.00"
486
393
  }
487
394
  ],
488
395
  "testName": "trie"