Exemplo n.º 1
0
 def coordinates(self):
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         xy = x + y
         x_y = x - y
         if (5 <= xy <= 15) and (-5 <= x_y <= 5):
             yield coord
Exemplo n.º 2
0
 def coordinates(self):
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         xy = x + y
         x_y = x - y
         if (5 <= xy <= 15) and (-5 <= x_y <= 5):
             yield coord
Exemplo n.º 3
0
 def coordinates(self):
     max_xy = self.width - self.height
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         xy = x - y
         if 0 <= xy <= max_xy:
             yield coord
Exemplo n.º 4
0
 def coordinates(self):
     max_xy = self.width - self.height
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         xy = x - y
         if 0 <= xy <= max_xy:
             yield coord
Exemplo n.º 5
0
 def coordinates(self):
     center = (self.width + 1) / 2
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         if (  ((x < center) and (x <= y < x + 4))
               or ((x >= center)
                   and ((self.width - x) <= y < (self.width - x + 4)))):
             yield coord
Exemplo n.º 6
0
 def coordinates(self):
     center = (self.width + 1) / 2
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         if (((x < center) and (x <= y < x + 4))
                 or ((x >= center) and ((self.width - x) <= y <
                                        (self.width - x + 4)))):
             yield coord
Exemplo n.º 7
0
 def coordinates(self):
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         if ((x > 6) or (y > 6)) and (-7 <= y - x <= 7):
             yield coord
Exemplo n.º 8
0
 def coordinates(self):
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         xy = x + y
         if xy >= (self.height - 1) and ((x > 6) or (y > 6)):
             yield coord
Exemplo n.º 9
0
 def coordinates(self):
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         xy = x + y
         if xy >= (self.height - 1) and xy < (self.height * 2 - 10):
             yield coord
Exemplo n.º 10
0
 def coordinates(self):
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         xy = x + y
         if xy >= 6:
             yield coord
Exemplo n.º 11
0
 def coordinates(self):
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         if ((x > 6) or (y > 6)) and (-7 <= y - x <= 7):
             yield coord
Exemplo n.º 12
0
 def coordinates(self):
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         xy = x + y
         if xy >= (self.height - 1) and ((x > 6) or (y > 6)):
             yield coord
Exemplo n.º 13
0
 def coordinates(self):
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         xy = x + y
         if xy >= (self.height - 1) and xy < (self.height * 2 - 10):
             yield coord
Exemplo n.º 14
0
 def coordinates(self):
     for coord in Pentominoes.coordinates(self):
         x, y = coord
         xy = x + y
         if xy >= 6:
             yield coord