2 ms·
They’re also useful when you want to cheaply reorder nodes without copying the elements.
by wtetzner 4y ago
They’re also useful when you want to cheaply reorder nodes without copying the elements.
- cerved 4y agoTrue. You could implement that using an array of structs where each struct contains indexes of the array to link other structures. instead of memory pointers, since they are 8 bytes in 64-bit applications. This way you get the nice properties of both linked lists and continuously allocated arrays