This repository was archived by the owner on Jul 23, 2021. It is now read-only.
Commit d12afee
committed
Initial implementation of SortedList.
Supports:
Constructor with custom key and less-than functions
add(), shift() and pop() between O(log16 N) and O(log32 N)
ES6 iteration at O(N)
first() and last() at O(1)
Many other functions are either absent or will crash when run. See my pull request for more information.1 parent db8573b commit d12afee
File tree
3 files changed
+934
-3
lines changed- src
- type-definitions
3 files changed
+934
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| 11 | + | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
| |||
64 | 65 | | |
65 | 66 | | |
66 | 67 | | |
| 68 | + | |
67 | 69 | | |
68 | 70 | | |
69 | 71 | | |
| |||
85 | 87 | | |
86 | 88 | | |
87 | 89 | | |
| 90 | + | |
88 | 91 | | |
89 | 92 | | |
90 | 93 | | |
| |||
119 | 122 | | |
120 | 123 | | |
121 | 124 | | |
| 125 | + | |
122 | 126 | | |
123 | 127 | | |
124 | 128 | | |
| |||
0 commit comments