test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
100,000 add | 6.56 | 152.37 | 1.86e-4 |
100,000 add & poll | 35.15 | 28.45 | 7.98e-4 |
diff --git a/README.md b/README.md index f8df6be..cf56bb8 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,8 @@ [//]: # (
) +> ***Our goal is to make every data structure as convenient and efficient as JavaScript's Array.*** + ## Installation and Usage ### npm @@ -212,6 +214,7 @@ Performance surpasses that of native JS/TS ### Conciseness and uniformity + In [java.utils](), you need to memorize a table for all sequential data structures(Queue, Deque, LinkedList),test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
100,000 add | 6.56 | 152.37 | 1.86e-4 |
100,000 add & poll | 35.15 | 28.45 | 7.98e-4 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
100,000 add | 6.49 | 154.00 | 1.90e-4 |
100,000 add & poll | 35.79 | 27.94 | 0.01 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
100,000 add | 83.54 | 11.97 | 8.43e-4 |
100,000 add randomly | 85.53 | 11.69 | 0.00 |
100,000 get | 115.17 | 8.68 | 0.00 |
100,000 iterator | 30.20 | 33.11 | 0.00 |
100,000 add & delete orderly | 151.05 | 6.62 | 0.00 |
100,000 add & delete randomly | 239.32 | 4.18 | 0.01 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
100,000 add | 85.30 | 11.72 | 7.38e-4 |
100,000 add randomly | 84.77 | 11.80 | 0.00 |
100,000 get | 113.74 | 8.79 | 0.00 |
100,000 iterator | 24.51 | 40.80 | 0.00 |
100,000 add & delete orderly | 152.17 | 6.57 | 0.01 |
100,000 add & delete randomly | 240.78 | 4.15 | 0.01 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 push | 44.31 | 22.57 | 0.01 |
100,000 push & shift | 5.50 | 181.72 | 0.00 |
Native JS Array 100,000 push & shift | 2451.35 | 0.41 | 0.39 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 push | 44.16 | 22.64 | 0.01 |
100,000 push & shift | 6.08 | 164.58 | 0.00 |
Native JS Array 100,000 push & shift | 2240.74 | 0.45 | 0.17 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 push | 20.56 | 48.65 | 0.00 |
1,000,000 push & pop | 25.77 | 38.81 | 0.00 |
1,000,000 push & shift | 26.35 | 37.95 | 0.00 |
100,000 push & shift | 2.54 | 394.25 | 4.24e-4 |
Native JS Array 100,000 push & shift | 2109.72 | 0.47 | 0.12 |
100,000 unshift & shift | 2.43 | 411.24 | 3.06e-4 |
Native JS Array 100,000 unshift & shift | 4275.22 | 0.23 | 0.35 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 push | 20.75 | 48.19 | 0.00 |
1,000,000 push & pop | 26.85 | 37.24 | 0.00 |
1,000,000 push & shift | 27.56 | 36.28 | 0.00 |
100,000 push & shift | 2.61 | 382.75 | 4.11e-4 |
Native JS Array 100,000 push & shift | 2388.65 | 0.42 | 0.15 |
100,000 unshift & shift | 2.50 | 399.53 | 3.59e-4 |
Native JS Array 100,000 unshift & shift | 4343.52 | 0.23 | 0.30 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 set | 85.09 | 11.75 | 0.02 |
Native JS Map 1,000,000 set | 211.60 | 4.73 | 0.03 |
Native JS Set 1,000,000 add | 165.56 | 6.04 | 0.01 |
1,000,000 set & get | 78.93 | 12.67 | 0.02 |
Native JS Map 1,000,000 set & get | 273.56 | 3.66 | 0.00 |
Native JS Set 1,000,000 add & has | 241.87 | 4.13 | 0.03 |
1,000,000 ObjKey set & get | 339.57 | 2.94 | 0.04 |
Native JS Map 1,000,000 ObjKey set & get | 294.22 | 3.40 | 0.02 |
Native JS Set 1,000,000 ObjKey add & has | 268.41 | 3.73 | 0.03 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 set | 87.12 | 11.48 | 0.02 |
Native JS Map 1,000,000 set | 211.63 | 4.73 | 0.03 |
Native JS Set 1,000,000 add | 167.62 | 5.97 | 0.01 |
1,000,000 set & get | 78.91 | 12.67 | 0.02 |
Native JS Map 1,000,000 set & get | 295.47 | 3.38 | 0.03 |
Native JS Set 1,000,000 add & has | 267.22 | 3.74 | 0.07 |
1,000,000 ObjKey set & get | 378.26 | 2.64 | 0.06 |
Native JS Map 1,000,000 ObjKey set & get | 344.04 | 2.91 | 0.06 |
Native JS Set 1,000,000 ObjKey add & has | 277.87 | 3.60 | 0.04 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
100,000 push | 43.89 | 22.78 | 8.04e-4 |
100,000 getWords | 82.90 | 12.06 | 0.00 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
100,000 push | 42.67 | 23.44 | 8.55e-4 |
100,000 getWords | 82.51 | 12.12 | 0.00 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
100,000 add | 281.55 | 3.55 | 0.00 |
100,000 add randomly | 353.66 | 2.83 | 0.02 |
100,000 get | 150.33 | 6.65 | 0.01 |
100,000 iterator | 33.26 | 30.07 | 0.01 |
100,000 add & delete orderly | 465.24 | 2.15 | 0.00 |
100,000 add & delete randomly | 634.77 | 1.58 | 0.02 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
100,000 add | 307.42 | 3.25 | 9.13e-4 |
100,000 add randomly | 373.75 | 2.68 | 0.01 |
100,000 get | 172.23 | 5.81 | 0.00 |
100,000 iterator | 25.90 | 38.61 | 0.00 |
100,000 add & delete orderly | 509.58 | 1.96 | 0.00 |
100,000 add & delete randomly | 690.44 | 1.45 | 0.02 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
10,000 RBTree add randomly | 7.62 | 131.29 | 8.51e-5 |
10,000 RBTree get randomly | 10.50 | 95.20 | 5.32e-5 |
10,000 RBTree add & delete randomly | 20.69 | 48.33 | 1.32e-4 |
10,000 AVLTree add randomly | 25.68 | 38.94 | 2.47e-4 |
10,000 AVLTree get randomly | 10.95 | 91.29 | 6.68e-5 |
10,000 AVLTree add & delete randomly | 48.33 | 20.69 | 3.14e-4 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
10,000 RBTree add randomly | 7.45 | 134.14 | 0.00 |
10,000 RBTree get randomly | 13.03 | 76.74 | 1.43e-4 |
10,000 RBTree add & delete randomly | 22.62 | 44.21 | 1.83e-4 |
10,000 AVLTree add randomly | 28.44 | 35.16 | 2.71e-4 |
10,000 AVLTree get randomly | 13.02 | 76.81 | 1.05e-4 |
10,000 AVLTree add & delete randomly | 54.46 | 18.36 | 0.00 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000 addVertex | 0.10 | 1.03e+4 | 1.01e-6 |
1,000 addEdge | 5.95 | 168.01 | 1.05e-4 |
1,000 getVertex | 0.10 | 1.05e+4 | 1.10e-6 |
1,000 getEdge | 23.44 | 42.67 | 0.00 |
tarjan | 194.66 | 5.14 | 0.00 |
topologicalSort | 151.88 | 6.58 | 0.01 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000 addVertex | 0.10 | 1.01e+4 | 8.01e-7 |
1,000 addEdge | 6.06 | 165.03 | 2.89e-4 |
1,000 getVertex | 0.10 | 1.05e+4 | 9.35e-7 |
1,000 getEdge | 23.80 | 42.02 | 0.00 |
tarjan | 193.59 | 5.17 | 0.01 |
topologicalSort | 148.99 | 6.71 | 0.01 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 push | 191.43 | 5.22 | 0.04 |
1,000,000 unshift | 171.35 | 5.84 | 0.01 |
1,000,000 unshift & shift | 151.25 | 6.61 | 0.00 |
1,000,000 addBefore | 264.87 | 3.78 | 0.07 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 push | 191.05 | 5.23 | 0.04 |
1,000,000 unshift | 186.38 | 5.37 | 0.06 |
1,000,000 unshift & shift | 151.27 | 6.61 | 0.00 |
1,000,000 addBefore | 267.57 | 3.74 | 0.07 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 push & shift | 173.29 | 5.77 | 0.05 |
10,000 push & pop | 235.53 | 4.25 | 0.01 |
10,000 addBefore | 278.19 | 3.59 | 0.01 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 push & shift | 163.01 | 6.13 | 0.03 |
10,000 push & pop | 246.05 | 4.06 | 0.04 |
10,000 addBefore | 275.54 | 3.63 | 0.01 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
100,000 add | 30.64 | 32.64 | 0.00 |
100,000 add & poll | 89.25 | 11.20 | 0.00 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
100,000 add | 30.54 | 32.75 | 0.00 |
100,000 add & poll | 89.20 | 11.21 | 0.00 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 push | 40.92 | 24.44 | 0.00 |
1,000,000 push & pop | 46.83 | 21.35 | 0.01 |
test name | time taken (ms) | executions per sec | sample deviation |
---|---|---|---|
1,000,000 push | 40.42 | 24.74 | 0.00 |
1,000,000 push & pop | 47.90 | 20.88 | 0.01 |