-
Notifications
You must be signed in to change notification settings - Fork 369
Sparse Set #24
Copy link
Copy link
Open
Labels
enhancementNew feature or requestNew feature or request
Description
A Sparse Set is a specialized data structure for storing elements from a large amount of possible values (e.g. natural numbers) that are used very sparingly, optimized for iteration, addition and removal to the set.
Use cases are for example are components attached to an entity in an Entity-Component System (ECS), if you are dealing with arrays of indices, but it can also be used comparably to a binary search tree or hash map, ideally outperforming both of them.
The main advantages of a Sparse Set are its performance which can be
O(1) for it's primary actions (source spareset/lib.rs) and its low memory footprint.
Example Implementations:
Further Reading:
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request