title: binary search on a array with a string prefix
body: <p>How can i go about adding the elements of a sorted array which contain a specific string prefix using binary search and those elements as the order they appear in the array to a arraylist..</p>
  
  <p>It is not hard to code but i am having difficulty with binary search. To use the string prefix the String class provides startswith. I just need help to start the binary search </p>
  
  <pre><code>public static &lt;T extends Comparable&lt;T&gt;&gt; ArrayList prefixMatch(T[] list,
              String prefix) {
  
  }
  </code></pre>