InterviewDB Question

Museum Visits: Maximize Exhibits Visited Within a Time Budget Using Scheduling

Question Details

Problem A museum has n exhibits. Each exhibit has a start_time, end_time, and value. You can visit at most one exhibit at a time and cannot overlap. Maximize the total value of exhibits visited. Example: Approach Sort by end time. Use DP: dp[i] = max value using exhibits 0..i where i is included. Use binary search to find the latest non-overlapping exhibit. Follow-ups What is the time complexity of this DP with binary search? If all exhibits have equal value, does this reduce to the classic acti…

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, Greedy, Binary Search, Dynamic Programming .