InterviewDB
Question
Picking Restaurant: Resolve Group Consensus on Restaurant Choice Using Voting
Question Details
Problem A group of friends must agree on a restaurant. Each person submits an ordered list of preferences (most to least preferred). Find the restaurant that is ranked first by the most people. If there is a tie, return the tied restaurants sorted alphabetically. If no restaurant is anyone's first choice (impossible if lists are non-empty, but handle the empty case), return an empty list. Example: Follow-ups What if no single restaurant wins a majority of first-choice votes? Describe how instant…
Full Details
🔒
Unlock all Karat questions
Full insider details, leaked discussions, and candidate experiences.
or every company, $100/year →About This Question
This is a reported interview question from a karat interview.
It covers the following topics: Coding .