4 ms·
The index/vector strategy is also perfect for basic trees, if you need to have cyclic dependencies between the nodes, and as a cherry on top it serializes super
by pimeys 3y ago
The index/vector strategy is also perfect for basic trees, if you need to have cyclic dependencies between the nodes, and as a cherry on top it serializes super well.
Requires a bit of boilerplate in the beginning, but pays off when actually needing to work with your data.
- cozzyd 3y agoBefore you know it, you'll have implemented pointers, a heap and some equivalent of malloc/free.