title: How to search in a Arraylist
body: <p>I created an arraylist of <code>Student</code> type. <code>Student</code> has name, subject information in it. Suppose my <code>ArrayList</code> has values like (sam, maths), (john, english), (mat, science). If i want to find out which student has science stream, then how to search it in an <code>ArrayList</code>.</p>
  
  <p>I think it may be done by using binarysearch or indexof methods, but not getting it right.</p>