4 ms·
You're basically describing the Rope. Fancier versions use self balancing trees, allowing other string operations to be fairly efficient too. https://en.wikipe
by shawn_w 1y ago
You're basically describing the Rope. Fancier versions use self balancing trees, allowing other string operations to be fairly efficient too.
https://en.wikipedia.org/wiki/Rope_(data_structure) https://en.wikipedia.org/wiki/Rope_(data_structure)
- danhau 1y agoWow, if that is true then that‘s the most succinct explanation of Ropes I have seen. Super helpful if you are trying to learn about them, like I am.
- Dylan16807 1y agoIt's partway to being a rope, I would say some balancing and the ability to replace substrings are crucial to a real rope.