def the_box(box, width=3, height=3):
    """Return all coordinates of the fields of the given box number.

    Args:
        box (int): The number of the box.
        width (int): The width of the sudoku.
        height (int): The height of the sudoku.

    Returns:
        list: The coordinates of the box with the given number.

    Raises:
        ValueError: If the box number is invalid.

    Example::
        >>> the_box(0, width=3, height=3)
        [(0, 0), (0, 1), (0, 2), (1, 0), (1, 1), (1, 2), (2, 0), (2, 1), (2, 2)]
    """
    if not 0 <= box < width * height:
        raise ValueError(
            "box must be less equal 0 and less than %d" % width * height)

    x = (box % height) * width
    y = (box // height) * height
    return [(y + i, x + j) for i in range(height) for j in range(width)]