2.0.0 • Published 3 years ago

djb2a v2.0.0

Weekly downloads
10,676
License
MIT
Repository
github
Last release
3 years ago

djb2a

DJB2a non-cryptographic hash function

DJB2a has good distribution and collisions are rare.

Install

$ npm install djb2a

Usage

import djb2a from 'djb2a';

djb2a('🦄🌈');
//=> 1484783307

It returns the hash as a positive integer.

Related

  • fnv1a - FNV-1a non-cryptographic hash function
  • sdbm - SDBM non-cryptographic hash function