Question
A company needs to schedule a maximum number of meetings
in a single conference room. Each meeting `i` has a start time `s_i` and an finish time `f_i`. Once a meeting starts, it must run to completion. Consider the following greedy strategy: 1. Sort all meetings by their start times in ascending order. 2. Select the first meeting. 3. From the remaining meetings, select the next meeting that starts after the previously selected meeting finishes. 4. Repeat until no more meetings can be selected. Given the meetings: `(s, f)` `M1: (1, 4)` `M2: (3, 5)` `M3: (0, 6)` `M4: (5, 7)` `M5: (8, 9)` `M6: (5, 9)` Which set of meetings will be selected by the described greedy strategy?Solution
Answer : B)`M3: (0, 6)` `M1: (1, 4)` `M2: (3, 5)` `M4: (5, 7)` `M6: (5, 9)` `M5: (8, 9)` 1. Select `M3 (0, 6)`. Current end time = 6. 2. Iterate through remaining: `M1 (1, 4)`: `1 < 6` (cannot select) `M2 (3, 5)`: `3 < 6` (cannot select) `M4 (5, 7)`: `5 < 6` (cannot select) `M6 (5, 9)`: `5 < 6` (cannot select) `M5 (8, 9)`: `8 >= 6` (can select). Select `M5`. Current end time = 9. 3. No more meetings. Selected: `M3, M5`.
Read the data carefully and answer the following questions
Units sold in five months. What is the average units sold per month?
Average number of Sold Nokia Mobile in all these 6 months is how much more or less than Average number of Sold Samsung Mobile in all these 6 months?
If the price of glossy lipstick and matte lipstick is Rs.250 and Rs.180 respectively, then find the total revenue generated by Sugar by selling lipstick...
What is the difference between the cost of fencing of R and that of Q?
Number of males working in department A is how much percent more than the number of females working in department D?
The question consists of two statements numbered “I and II” given below it. You have to decide whether the data provided in the statements are suffi...
Find the ratio of Umbrella sold in cities E and F together to Raincoat sold in cities C and D together.
Number of i5 processor laptops in Computer world is what percent the number of i3 processor laptops in Computer care?
If the number of butter cookies baked on Wednesday are increased by 5/16 and there are two types of butter cookies baked on Wednesday (chocolate and van...
Find the average number of platinum tickets sold in theatre B and D, if total number of tickets available in theatre B and D are 250 and 300 respectively.