def _sort_imdb_scores(
    year_elements: list, movie_elements: list, imdb_elements: list
) -> tuple:
    """Sorts the year, movie and IMDB web elements according to the IMDB score.

    Args:
        year_elements (list): Web elements of the movies' release years.
        movie_elements (list): Web elements of the movies' names.
        imdb_elements (list): Web elements of the movies' IMDB scores.

    Returns:
        tuple: year, movie and IMDB web elements in sorted order (according to
               IMDB score).
    """
    year_elements, movie_elements, imdb_elements = zip(
        *sorted(
            zip(year_elements, movie_elements, imdb_elements),
            key=lambda x: x[2].getText().replace("IMDB", "").strip()
            + "-"
            + x[0].getText().replace("year", ""),
            reverse=True,
        )
    )

    return year_elements, movie_elements, imdb_elements