Open saxbophone opened 1 year ago
I recently rewrote my "shifted array (sharray)" implementation to be fully working. It's inspired by the standard library's deque but implemented in a simpler way. It gives $\mathcal{O}(1)$ random access and amortised $\mathcal{O}(1)$ push and pop at front and back. It's convenient for arby if we can retain the ability to quickly push and pop digits at either end, perhaps we should perfect that container we've built, rather than use vector.
We should stop using
our custom-built storage typea linked list for the digits,vector is constexpr on many platforms now and it's probably faster than the hand-built structure we have been usinglet's use a constexpr deque implementation instead.