What's wrong with using lower_bound? Can someone help?

  • 0

    it always says runtime error to use custom compare function with lower_bound.

    auto iter = lower_bound(intervals.begin(), intervals.end(), newInterval, [](Interval l, Interval r){return l.start < r.start;});


Log in to reply

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.