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

combine_unordered_soft_hash_* should not use xor #1

Open
dougives opened this issue Aug 18, 2021 · 0 comments
Open

combine_unordered_soft_hash_* should not use xor #1

dougives opened this issue Aug 18, 2021 · 0 comments

Comments

@dougives
Copy link
Owner

dougives commented Aug 18, 2021

return reduce(xor, map(soft_hash_64, s))

Should add and multiply by _GOLDEN_RATIO instead of xor. Xoring will result in sequences containing the same repeated value, but of different lengths, to have the same hash.

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

No branches or pull requests

1 participant