title: Check overlapping series in C#
body: <p>I am making an application where the user adds start and end to define a range</p>
  
  <p>The condition is that the range should not overlap:</p>
  
  <p>How to check whether a number range is not overlapping e.g.</p>
  
  <ol>
  <li>Range 1  Start 5  End 15</li>
  <li>Range 2  Start 1  End 4</li>
  <li>Range 3  Start 16 End 20</li>
  <li>Range 4  Start 2  End 4</li>
  </ol>
  
  <p>So the Range 4 makes the set invalid, how do I check this in C#.</p>
  
  <p>Further the user can add the range in any order as in the example above, the entire series should be non overlapping.</p>
  
  <p>Thanks for the help suggestion.</p>
  
  <p>Regards,
  Sakshi</p>
  
  <p>Answer:</p>
  
  <p>I made the solution is it correct:
  If start and end is the range which needs to be validated then </p>
  
  <ol>
  <li>start >startRange and start less than endRange     </li>
  <li>end>startRange and end less than endRange</li>
  </ol>
  
  <p>The above 2 condition validates that the series is overlapping.</p>
  
  <p>Where startRange and endRange is the start and end for all existing ranges.</p>