Advertisement
exkappa

Untitled

Dec 10th, 2018
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. public void updateDomains(Tile t1, Tile t2){
  2. int n = t1.domain.size();
  3. for(int value:t1.domain.domain){
  4. t1.setValue(value);
  5. for(int t2.x = 0; t2.x < size; t2.x++) {
  6. for (int t2.y = 0; t2.y < size; t2.y++) {
  7. if (t2.x != t1.x || t2.y != t1.y) {
  8. if (!con.checkconsistency(t1, t2))
  9. t1.domain.deleteElement(k);
  10. }
  11. }
  12. }
  13. }
  14. t1.setValue(null);
  15. t2.setValue(null);
  16. if(n == 0)
  17. t2.domain.deleteElement(value);
  18.  
  19. }
  20.  
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement