def _stringify_maze(grid):
    """
    Converts a grid back into its string form

    Args:
        grid: the 2D grid maze representation

    Returns:
        The string version of the maze as it is in a file
    """
    return "\n".join(["".join(line) for line in grid])