摘要:
Q:Given life time of different animals. Find period when maximum number of animals lived. ex [5, 11], [6, 18], [2, 5],[3,12] etc. year in which max no animals exists.A:Input intervals (or lifetimes): [5, 11], [6, 18], [2, 5], [3,12]1. Put the end and start times of the intervals in one array. Sort i 阅读全文