code below

```
bool canAttendMeetings(vector<Interval>& intervals) {
sort(intervals.begin(), intervals.end(), [](const Interval& a, const Interval& b){ return a.start < b.start; });
int currend=INT_MIN;
for(int i = 0; i < intervals.size(); ++i) {
if(intervals[i].start < currend) { return false; }
currend = intervals[i].end;
}
return true;
}
```