FNV与FNV-1a Hash算法说明

FNV与FNV-1a哈希算法的核心在于使用不同的异或和乘法顺序。FNV-1a算法的FNV_prime和offset_basis参数与FNV-1相同,但算法中异或和乘法的操作顺序不同。文章详细介绍了不同位数的FNV_prime和offset_basis参数,以及这些参数如何影响哈希效果。
摘要由CSDN通过智能技术生成

The core of the FNV hash

The core of the FNV-1 hash algorithm is as follows:

hash = offset_basis
for each octet_of_data to be hashed
 hash = hash * FNV_prime
 hash = hash xor octet_of_data
return hash

The offset_basis andFNV_prime can be found in theparameters of the FNV-1/FNV-1a hash section below.

FNV-1a alternate algorithm

There is a minor variation of the FNV hash algorithm known as FNV-1a: <
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值