Skip to content

hammingManyU32

hammingManyU32(reference, candidates, maxDistance?): Uint32Array

Like hammingMany, but returns the distances in a Uint32Array.

Slots that hammingMany returns as null (length mismatch, or filtered out by maxDistance) become the sentinel 0xffffffff (4294967295), since a Uint32Array cannot hold null. Check for it with value === 0xffffffff before treating a slot as a real distance.

Parameter Type
reference string
candidates readonly string[]
maxDistance? number | null

Uint32Array