Hat Assignment With Points
CodingOnsiteSoftware EngineerReported Sep, 2026New
Company question banks are included with the Insider plan.
You have n people and H distinct hats, numbered from 0 to H - 1. Each person has a list of acceptable hats in preferences[i]. Assign exactly one acceptable hat to each person, using each...