grigala
v = v + (digest[i] & 0xff) * (int) Math.pow(256, i);
v = v + (digest[i] and 0xff) * Math.pow(256.0, i.toDouble()).toInt()