title: Comparing two ArrayLists - one as a subset of the other
body: <p>I know that we can use the <code>containsAll</code> method while comparing two <code>ArrayLists</code> to check if one is a subset of the other. But this is what I would like. Consider an </p>
  
  <p><code>ArrayList super = 1,2,3,4,5,6,7,8,9,10</code> </p>
  
  <p>and an </p>
  
  <p><code>ArrayList sub1 = 1,2,3,4</code> </p>
  
  <p>and another </p>
  
  <p><code>ArrayList sub2 = 2,4,6,8</code>. </p>
  
  <p>Now, if I did </p>
  
  <p><code>super.containsAll(sub1)</code>, it would evaluate to <code>true</code> because <code>sub1</code> is contained within <code>super</code>. </p>
  
  <p>If I did <code>super.containsAll(sub2)</code>, it would also evaluate to <code>true</code> because the numbers 2,4,6 and 8 are contained in <code>super</code>. </p>
  
  <p>I would like to know if there's a way to check two <code>ArrayLists</code> so that <code>super.containsAll(sub2)</code> evaluates to <code>false</code> as the numbers in <code>sub2</code> don't appear in the same order in <code>super</code>.</p>