from typing import List


def play_bingo_draw(draw: int, boards: List[List[List[int]]],
    marks: List[List[List[bool]]]) -> List[int]:
  """Plays a bingo draw.

  Marks off ``draw`` on any boards it appears on, and returns a list of boards
  that won.

  :param draw: the number drawn.
  :param boards: a list of bingo boards.
  :param marks: a list of marks. must correspond one-to-one with boards.
    will be updated in-place by this method.
  :return: a (possibly empty) list of indices of boards that won this round.
  """
  winning_boards = []
  for i in range(len(boards)):
    for j in range(len(boards[i])):
      for k in range(len(boards[i][j])):
        if boards[i][j][k] != draw:
          continue

        marks[i][j][k] = True

        winning_row = True
        winning_col = True
        for jj in range(len(boards[i])):
          winning_col &= marks[i][jj][k]
        for kk in range(len(boards[i][j])):
          winning_row &= marks[i][j][kk]

        if winning_row or winning_col:
          winning_boards.append(i)

  return winning_boards