title: std::set, how do lower_bound and upper_bound work?
body: <p>I have this simple piece of code:</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include &lt;set&gt;
  
  using std::set;
  
  int main(int argc, char argv) {
     set&lt;int&gt; myset;
     set&lt;int&gt;::iterator it_l, it_u;
     myset.insert(10);
     it_l = myset.lower_bound(11);
     it_u = myset.upper_bound(9);
  
     std::cout &lt;&lt; *it_l &lt;&lt; " " &lt;&lt; *it_u &lt;&lt; std::endl;
  }
  </code></pre>
  
  <p>This prints 1 as lower bound for 11, and 10 as upper bound for 9.</p>
  
  <p>I don't understand why 1 is printed. I was hoping to use these two methods to get a range of values for given upper bound / lower bound.</p>