Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
def BookRecommender(book_name):
book_list_name = []
book_id = df2[df2['title'] == book_name].index
book_id = book_id[0]
for newid in idlist[book_id]:
book_list_name.append(df2.loc[newid].title)
return book_list_name
BookNames = BookRecommender('Harry Potter and the Half-Blood Prince (Harry Potter #6)')
BookNames
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment