Jump to content

Set puzzle: Difference between revisions

m
Small improvement in second D entry
m (Better name in second D entry)
m (Small improvement in second D entry)
Line 672:
 
retry:
autoconst draw = deck.randomSample(nDraw).map!(t => [t[]]).array;
autoconst sets = draw.combinations(3).array.filter!((string[][] cs) =>
cs.array.transposed.all!(t => t.array.sort().uniq.count % 2)).array;
if (sets.length != nGoal)
Cookies help us deliver our services. By using our services, you agree to our use of cookies.