Best way to find duplicates from two List : <p>In Java, I have two ArrayLists:</p>

<pre><code>A = [Ab, cd, df, FE, ...]
B = [ab, cde, de, fE, ...]
</code></pre>

<p>If the lists are a little big, the brute force method is very slow:</p>

<pre><code>for(String a : A) {
  for(String b : B) {
     if(a.equalsIgnoreCase(b)) {
        System.out.println("duplicate: " + a "-&gt;" + b);
     }
  }
}
</code></pre>

<p>What's the best way to make it faster, but not super complicated to implement? </p>
