Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How about adding Bloom Filter data structure? #162

Open
ericbreyer opened this issue Feb 3, 2023 · 2 comments
Open

How about adding Bloom Filter data structure? #162

ericbreyer opened this issue Feb 3, 2023 · 2 comments

Comments

@ericbreyer
Copy link

I think Bloom Filters are pretty cool. They are a fairly fast and space-efficient implementation of a set with the trade-off that "False positive matches are possible, but false negatives are not – in other words, a query returns either 'possibly in set' or 'definitely not in set'". Interesting applications could be guarding against expensive searches if the element definitely does not exist or if you only care about an element being outside the set.

I have a very rudimentary implementation of a (counting) bloom filter in cpp here (porting to C is trivial). https://github.com/ericbreyer/redBlackTreeInCpp/blob/master/bloomFilter/bloomFilter.cpp

Wikipedia on bloom filters: https://en.wikipedia.org/wiki/Bloom_filter
Wikipedia on counting bloom filters: https://en.wikipedia.org/wiki/Counting_Bloom_filter

Also skip lists could be cool?

@srdja
Copy link
Owner

srdja commented Feb 4, 2023

@ericbreyer
Would be cool for sure! I certainly thought about implementing it (and many others too), but never really got around to actually doing it. But if you feel like doing it, that would be really cool!

@ericbreyer
Copy link
Author

Cool, I will work on that! Is there any guide or docs for how the testing should be structured?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants