title: Suggest data structure suitable for key range lookup
body: <p>I am looking for data structure similar to SCG.Dictionary but having number ranges as keys.</p>
  
  <p>Main operation where the most of performance is required would be lookup for keys overlapping with the specified range.</p>
  
  <p>For example, assuming the following map</p>
  
  <pre><code>[ 5, 15] -&gt; King
  [35, 50] -&gt; Bear
  [25, 40] -&gt; Doll
  </code></pre>
  
  <p>when [10, 30] is passed to search algorithm it must reply with the following entries:</p>
  
  <pre><code>[ 5, 15] -&gt; King
  [25, 40] -&gt; Doll
  </code></pre>
  
  <p>Ideally search method should return IEnumerable rather than copying results into intermediate container. Similarly to <a href="https://msdn.microsoft.com/en-us/library/dd381801(v=vs.110).aspx" rel="noreferrer">SortedSet.GetViewBetween</a></p>
  
  <p>Usage pattern would be something along the lines of</p>
  
  <pre><code>var lookup = new RangeDictionary&lt;int&gt;();
  lookup.Add( 5, 15, 'King' );
  lookup.Add( 35, 50, 'Bear' );
  lookup.Add( 25, 40, 'Doll' );
  
  var results = lookup.FindIntersection( 10, 30 );
  foreach( var pair in results )
    Console.WriteLine( "[{0}, {1}] -&gt; {2}", pair.Key.From, pair.Key.To, pair.Value );
  </code></pre>
  
  <p>Are there any ready made solutions?</p>