Skip to content

identify_favorite_movies - Favorites is being rebuilt on each function call #3

@konpsar

Description

@konpsar

In the way identify_favorite_movies is implemented, the whole favorites list is being rebuilt each time function is called. And previous list is deleted node by node.
For efficiency, wouldn't it be better to have a pointer in each list (previous favorites and history list) and check movies one by one to see if it exists in favorites already? (and if not, create a new node in favorites list?)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions