Company: Ring central_25july
Difficulty: medium
Largest Subset Problem Description In a scheduling system, there are n events represented by two arrays, start and finish , both of size n. The i-th event begins at start[i] and ends at finish[i] (where 0 ≤ i < n). A subset of these events is considered high-priority if at least one event within it overlaps or intersects with every other event in the subset. Determine the maximum size of a high-priority subset of events. Notes: Events that overlap at their start or end times are considered to intersect. There may be multiple events with the same start and end times. Complete the function getSubsetLength in the editor with the following parameter(s): int start[n] : event start times int finish[n] : event end times Returns: int : length of the largest high-priority subset of events Examples Example 1: Input: n = 4, start = [1, 2, 3, 4], finish = [2, 3, 5, 5] Output: 3 Explanation: The largest high-priority subset is {[2, 3], [3, 5], [4, 5]} where event [3, 5] intersects the remaini