3 ms·
Pre-allocating the size of the array lowers that number even more. Persistent data structure are really useful, and are (often) magnitudes more efficient than
by fredrikholm 4y ago
Pre-allocating the size of the array lowers that number even more.
Persistent data structure are really useful, and are (often) magnitudes more efficient than DIY-immutable data structures.
Imperative ones however, like you mentioned, are often (comparatively) near ideal by virtue of being imperative.