title: compare function for upper_bound / lower_bound
body: <p>I want to find the first item in a sorted vector that has a field less than some value x.<br>
  I need to supply a compare function that compares 'x' with the internal value in MyClass but I can't work out the function declaration.<br>
  Can't I simply overload '&lt;' but how do I do this when the args are '&amp;MyClass' and 'float' ?</p>
  
  <pre><code> float x;
   std::vector&lt; MyClass &gt;::iterator last = std::upper_bound(myClass.begin(),myClass.end(),x);
  </code></pre>