iefserge / jenkins-hash

Jenkins hash function

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

SYNOPSIS

JavaScript port of lookup3.c hash function by Bob Jenkins

http://www.burtleburtle.net/bob/c/lookup3.c

USAGE

var hash = require('./').hashlittle;
hash(new Uint8Array([1, 2, 3]), 0xdeadbeef); // 0x271b32ed

hashlittle(buf, initval = 0)

buf - buffer to hash

initval - any 32bit integer number

return - 32bit hash

About

Jenkins hash function


Languages

Language:JavaScript 100.0%