looking for a D3 stl project

Nickolay Bukreyev buknik95 at ya.ru
Mon Jan 15 21:48:38 UTC 2024


On Monday, 15 January 2024 at 21:01:54 UTC, monkyyy wrote:
> I view data as having a place where it actually exists, and 
> would like filter/chunks/slide to fundamentally leave ".index" 
> alone

I’d argue that having an index is not a must-have requirement for 
a data structure.

1. Singly and doubly linked lists contain data that actually 
exists.
2. (Imperative) concatenation of two doubly linked lists is 
(should be) an `O(1)` operation.
3.  It invalidates indices of the right-hand side list in the 
process.

Therefore, if a list stores its indices, it cannot implement 
concatenation in `O(1)` time. That is, without invalidating its 
ranges/iterators created prior to concatenation.


More information about the Digitalmars-d mailing list