pub fn compute_checksum(assignment: &[bool]) -> u64Expand description
Computes an FNV-1a checksum for a boolean assignment.
FNV-1a (Fowler-Noll-Vo) is a fast, non-cryptographic hash function suitable for integrity verification. The implementation incorporates both the index and value to ensure position-sensitivity.
§Arguments
assignment- The boolean assignment to checksum
§Returns
A 64-bit FNV-1a hash of the assignment.
§Example
ⓘ
let checksum = compute_checksum(&[true, false, true]);
assert_ne!(checksum, 0);