Longest nonoverlapping interval