title: C++ <int*, std::vector<int, std::allocator<int> > >’ requested?? on a simple 20 line program
body: <p>I've been trying to compile and have played around with the ampersands and still can't figure out what the error is. Any ideas? </p>
  
  <p>the following is the only compiling error that I've been getting. </p>
  
  <pre><code> error: conversion from ‘void’ to non-scalar type ‘__gnu_cxx::__normal_iterator&lt;int*, std::vector&lt;int, std::allocator&lt;int&gt; &gt; &gt;’ requested
  </code></pre>
  
  <p>and the line that's causing the error is </p>
  
  <pre><code>    iterator it2 = nth_element (v_best.begin(), v_best.begin()+n, v_best.end());
  </code></pre>
  
  <p>Thank you so much!</p>