beaucoup
All checks were successful
Linux arm64 / Build (push) Successful in 1m47s

This commit is contained in:
2025-01-10 14:47:20 +01:00
parent 34cf7b5da8
commit 09ba8c00cb
13 changed files with 147 additions and 46 deletions

View File

@@ -0,0 +1,15 @@
package sudoku.constraint;
import sudoku.Bloc;
import sudoku.Case;
import sudoku.Sudoku;
public class BlockConstraint implements IConstraint{
@Override
public boolean canBePlaced(final Sudoku s, int x, int y, int newSymbolIndex) {
Bloc bloc = s.getCase(x, y).getBloc();
return !bloc.getCases().contains(new Case(newSymbolIndex));
}
}