title: What is the most elegant way to check if all values in a vector<bool> are true?
body: <p>This question is similar to this question:
  <a href="https://stackoverflow.com/questions/8260881/what-is-the-most-elegant-way-to-check-if-all-values-in-a-boolean-array-are-true">What is the most elegant way to check if all values in a boolean array are true?</a></p>
  
  <p>But for <code>vector&lt;bool&gt;</code> in c++.</p>
  
  <p>How can use <code>all_of</code> for this purpose (for example I want to check the value between ranges, element 10 to 20) so I can not use <code>begin</code> and <code>end</code>.</p>