Created
April 9, 2017 18:09
-
-
Save nathankrishnan/72e9ecc599c49c2890249a83a319d696 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private func computeHashes(_ value: T) -> [Int] { | |
var results: [Int] = [] | |
for hashFunction in hashFunctions { | |
let value = abs(hashFunction(value)) % array.count | |
results.append(value) | |
} | |
return results | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment