introduce bitloops

This commit is contained in:
mike
2026-01-14 03:30:19 +01:00
parent b0b10d356a
commit 19f235ae59
6 changed files with 123 additions and 142 deletions

View File

@@ -359,7 +359,7 @@ public class Main {
val stack = new int[STACK_SIZE];
var swe = new SwedishGenerator(rng, stack);
var mask = swe.generateMask(opts.pop, opts.gens, Math.max(opts.pop, (int) Math.floor(opts.pop * 1.5)));
var filled = fillMask(rng, mask, dict.index());
var filled = fillMask(rng, mask.toGrid(), dict.index());
TOTAL_NODES.addAndGet(filled.stats().nodes);
TOTAL_BACKTRACKS.addAndGet(filled.stats().backtracks);
@@ -380,7 +380,7 @@ public class Main {
);
if (filled.ok() && (opts.minSimplicity <= 0 || filled.stats().simplicity >= opts.minSimplicity)) {
return new PuzzleResult(swe, dict, new Gridded(mask), filled);
return new PuzzleResult(swe, dict, new Clued(mask), filled);
}
if (opts.verbose && filled.ok()) {