NeetCode #791LC-649MediumGreedyNC 250
← Back to All Problems#791 · #649 · Dota2 Senate(Dota2 参议院)
📌 Problem Statement & Constraints
In the Dota2 senate, each senator is from the
Radiant or Dire party. In each round, senators act in order; each may ban one opposing senator (who then loses all future rights). A senator with no rights is skipped. Return the winning party. Constraints: 1 <= senate.length <= 10^4, senate[i] is R or D.🔒
Sign In to Unlock Full Solutions for All 973 Problems
Sign in to access step-by-step logic, benchmark Python3 code, complexity breakdown, and offline export!