public static uint Hash(byte[] data, uint seed = 0)
const uint m = 0x5bd1e995;
int length = data.Length;
uint h = seed ^ (uint)length;
uint k = BitConverter.ToUInt32(data, i);
h ^= (uint)(data[i + 2] << 16);
h ^= (uint)(data[i + 1] << 8);
public static void Main(string[] args)
const UInt64 product1 = 1;
const UInt64 customer1 = 1;
var bytesProduct1 = BitConverter.GetBytes(product1);
UInt64 hashProduct1 = Hash(bytesProduct1);
var combinedProduct1Customer1 = (hashProduct1 ^ customer1);
var bytesCombinedProduct1Customer1 = BitConverter.GetBytes(combinedProduct1Customer1);
UInt64 hashCombinedProduct1Customer1 = Hash(bytesCombinedProduct1Customer1);
Console.WriteLine($"Hash value: {hashProduct1}, {hashCombinedProduct1Customer1}");