InterviewDB Question

Friends Purchases - Find Items Bought by Friends but Not by User

Question Details

Problem Given: A dict purchases: {user_id -> set of item_ids} that a user has bought A list friends: list[str] of the current user's friend IDs The current user_id Return all items that at least one friend has purchased but the current user has not,…

Full Details

🔒

Unlock full leaked content

Full insider details, leaked discussions, and candidate experiences.

Get Premium →

Topics

Coding Onsite Phone