introduce bitloops
This commit is contained in:
@@ -97,7 +97,7 @@ public class Main {
|
||||
}
|
||||
|
||||
section("Result");
|
||||
res.filled().calcSimpel();
|
||||
res.filled().stats().simplicity = FillResult.calcSimpel(res.slots());
|
||||
info(String.format(Locale.ROOT, "simplicity : %.2f", res.filled().stats().simplicity));
|
||||
|
||||
section("Mask");
|
||||
@@ -396,9 +396,9 @@ public class Main {
|
||||
TOTAL_NODES.addAndGet(filled.stats().nodes);
|
||||
TOTAL_BACKTRACKS.addAndGet(filled.stats().backtracks);
|
||||
if (filled.ok()) {
|
||||
filled.calcSimpel();
|
||||
val simpel = FillResult.calcSimpel(slotInfo);
|
||||
TOTAL_SUCCESS.incrementAndGet();
|
||||
TOTAL_SIMPLICITY.addAndGet((long) (filled.stats().simplicity * 100));
|
||||
TOTAL_SIMPLICITY.addAndGet((long) (simpel * 100));
|
||||
}
|
||||
|
||||
var name = Thread.currentThread().getName();
|
||||
@@ -413,7 +413,7 @@ public class Main {
|
||||
);
|
||||
|
||||
if (filled.ok() && (opts.minSimplicity <= 0 || filled.stats().simplicity >= opts.minSimplicity)) {
|
||||
return new PuzzleResult(new Clued(mask), filled);
|
||||
return new PuzzleResult(new Clued(mask), slotInfo, filled);
|
||||
}
|
||||
|
||||
if (opts.verbose && filled.ok()) {
|
||||
|
||||
Reference in New Issue
Block a user