How to find index position of an element in a list when contains returns true
<p>I've got a <code>List</code> of <code>HashMap</code> so I'm using <code>List.contains</code> to find out if the list contains a specified <code>HashMap</code>. In case it does, I want to fetch that element from the list, so How do I find out index position of where the element is?</p>

<pre><code>    List benefit = new ArrayList();
    HashMap map = new HashMap();
    map.put("one", "1");
    benefit.add(map);
    HashMap map4 = new HashMap();
    map4.put("one", "1");

    System.out.println("size: " + benefit.size());
    System.out.println("does it contain orig: " + benefit.contains(map));
    System.out.println("does it contain new: " + benefit.contains(map4));

    if (benefit.contains(map4))
        //how to get index position where map4 was found in benefit list?
</code></pre>
