There was an error while loading. Please reload this page.
1 parent 0ac7d1f commit dbde089Copy full SHA for dbde089
1 file changed
hashes/joaat.py hashes/jenkins_one_at_a_time.pyhashes/joaat.py renamed to hashes/jenkins_one_at_a_time.py
@@ -2,19 +2,19 @@
2
The Bob Jenkins hash is a fast, non-cryptographic hash function
3
designed for general-purpose use, such as hash table lookups.
4
5
-source: https://en.wikipedia.org/wiki/Jenkins_hash_function
+https://en.wikipedia.org/wiki/Jenkins_hash_function
6
"""
7
8
9
-def joaat(key: str) -> int:
+def jenkins_one_at_a_time(key: str) -> int:
10
11
Calculate Jenkins One-at-a-Time hash for a key.
12
13
- >>> joaat("apple")
+ >>> jenkins_one_at_a_time("apple")
14
2297466611
15
- >>> joaat("test")
+ >>> jenkins_one_at_a_time("test")
16
1064684737
17
- >>> joaat("")
+ >>> jenkins_one_at_a_time("")
18
0
19
20
hash_value = 0
0 commit comments