fn: hash
[contents]
f++ :
n++ :
Contents
Syntax
The syntax for
hash{option}(string)
@hash{option}(string)
Description
The
code | description |
---|---|
A simple hash function from Robert Sedgwicks Algorithms in C book, with some added some simple optimizations to the algorithm in order to speed up its hashing process | |
A bitwise hash function written by Justin Sobel | |
based on work by Peter J. Weinberger of Renaissance Technologies. The book Compilers (Principles, Techniques and Tools) by Aho, Sethi and Ulman, recommends the use of hash functions that employ the hashing methodology found in this particular algorithm | |
Similar to the PJW Hash function, but tweaked for 32-bit processors. It is a widley used hash function on UNIX based systems | |
This hash function comes from Brian Kernighan and Dennis Ritchie's book "The C Programming Language". It is a simple hash function using a strange set of possible seeds which all constitute a pattern of 31....31...31 etc, it seems to be very similar to the DJB hash function | |
This is the algorithm of choice which is used in the open source SDBM project. The hash function seems to have a good over-all distribution for many different data sets. It seems to work well in situations where there is a high variance in the MSBs of the elements in a data set | |
An algorithm produced by Professor Daniel J. Bernstein and shown first to the world on the usenet newsgroup comp.lang.c. It is one of the most efficient hash functions ever published | |
An algorithm proposed by Donald E. Knuth in The Art Of Computer Programming Volume 3, under the topic of sorting and search chapter 6.4 | |
Fowler–Noll–Vo is a non-cryptographic hash function created by Glenn Fowler, Landon Curt Noll, and Kiem-Phong Vo | |
Another non-cryptographic hash function, not a lot of information about it is available | |
An algorithm produced by Arash Partow (developer of these hasing algorithms along with |
|
code | description |
Note: The hash functions available with Nift come from General Purpose Hash Function Algorithms (GitHub) by Arash Partow (the same person who makes
Options
The following options are available for
option | description |
---|---|
parameter specifies file to hash contents of | |
option | description |
f++ example
Examples of
hash("hello, world!") hash("hello, world!", FNV) hash{f}(file.txt, AP)
n++ example
Examples of
@hash("hello, world!") @hash("hello, world!", FNV) @hash{f}(file.txt, AP)