Available question text
Given m binary rows (n ≤ 5), find any nonempty subset of row indices such that for each column the number of 1s in the subset is at most floor(k/2) where k is the subset size. The core challenge is to balance per-column 1-counts against subset size — with small n you can encode rows as bitmasks and use frequency-based enumeration of mask combinations to find a compatible subset.
Related questions
Continue with questions that share topics or the same question type.
Sources · 1 reference
These records explain where the question appears. A company tag or candidate report does not guarantee a future interview question.
Hello Interview · 1 record
No company association
Leetcode 2732. Find a Good Subset of the Matrix
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source