Insufficient data in question

What is the maximum amount of time person has?
I’m unable to understand, why he is able to do only 0th and 2nd activity, why not 1st activity?

Question: https://online.codingblocks.com/app/player/178555/content/173730/5280/code-challenge

Hello @mohaktrivedi in this question we will decide this with the help of the ending time of the meeting:
for this test case:
1
3
10 20
12 15
20 30
like suppose: if there are 3 element meetings in total then the person can attend the meetings which will end before the starting time of the other meeting so for that we will sort the meetin on the basis of their ending time and then we will make our comparison.
like in this the person is in the 0th meeting and then we can see that before the ending of the current meeting the other meeting is started and that’s why we have to skip the second meeting and check for the 2nd meeting.
in this way he is ale to attend only 2 meetings.
if you still have any doubt you can ask here:
Happy Learning!!

@tusharaggarwal272 Thanks for the clear explanation. Marked as resolved.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.