introduce bitloops

This commit is contained in:
mike
2026-01-20 01:57:21 +01:00
parent 7e5e363a3e
commit d1c448e1cb
7 changed files with 239 additions and 85 deletions

View File

@@ -84,7 +84,7 @@ public record SwedishGenerator() {
x = y;
return y;
}
static final byte[] BYTE = new byte[]{ 0, 1, 2, 3/*,4, 5*/ };
static final byte[] BYTE = new byte[]{ 0, 1, 2, 3, 4, 5 };
public byte randomClueDir() { return rand(BYTE); }
public <T> T rand(T[] p) { return p[(int) (((nextU32() & 0xFFFFFFFFL) % ((long) p.length)))]; }
public byte rand(byte[] p) { return p[(int) (((nextU32() & 0xFFFFFFFFL) % ((long) p.length)))]; }