how to check overlapping of multiple number ranges injavascript : <p>I have a problem in javascript in which i need to determine if the set of number ranges has overlapping. 
examples : </p>

<p>1 - 5,
4 - 6,
7 - 8
(has overlap)</p>

<p>1 - 5,
6 - 8,
9 - 12
(has no overlap)</p>

<p>thanks in advance!</p>
