Back to problems

Friend Recommendation II

Object-Oriented Programming · Meta · Medium

Requirements Q1 — Correct the filtering defect in valid_recommend. A common issue is allowing the requesting user and/or people already connected to them into the recommendation pool. Q2 — Build random_recommend. Select a random user who is not already a friend. Include the class signature in your AI prompt so its result conforms to the established interface. Q3 — Recommend the top K users by mutual friends. Assign every eligible user the score friends(u) ∩…

Checking your access…