title: iterate through two std::lists simultaneously
body: <p>Sorry if this is too simple a question.</p>
  
  <p>Prior error checking ensures <code>l1.size() == l2.size()</code>.</p>
  
  <pre><code>std::list&lt;object1&gt;::iterator it1 = l1.begin();
  std::list&lt;object2&gt;::iterator it2 = l2.begin();
  
  while(it1 != l1.end() &amp;&amp; it2 != l2.end()){
  
    //run some code
  
    it1++;
    it2++;
  }
  </code></pre>
  
  <p>Is this a reasonable approach, or is there a more elegant solution? Thanks for your help.</p>