docs: def liveNeighbours(self, y, x):
          """Returns the number of live neighbours."""
          count = 0
          if y > 0:
              if self.table[y - 1][x]:
                  count = count + 1
              if x > 0:
                  if self.table[y - 1][x - 1]:
                      count = count + 1
              if self.width > (x + 1):
                  if self.table[y - 1][x + 1]:
                      count = count + 1
  
          if x > 0:
              if self.table[y][x - 1]:
                  count = count + 1
          if self.width > (x + 1):
              if self.table[y][x + 1]:
                  count = count + 1
  
          if self.height > (y + 1):
              if self.table[y + 1][x]:
                  count = count + 1
              if x > 0:
                  if self.table[y + 1][x - 1]:
                      count = count + 1
              if self.width > (x + 1):
                  if self.table[y + 1][x + 1]:
                      count = count + 1
  
          if self.toroidal:
              if y == 0:
                  if self.table[self.height - 1][x]:
                      count = count + 1
              if y == self.height - 1:
                  if self.table[0][x]:
                      count = count + 1
              if x == 0:
                  if self.table[y][self.width - 1]:
                      count = count + 1
              if x == self.width - 1:
                  if self.table[y][0]:
                      count = count + 1
  
          return count