title: Find first element by predicate
body: <p>I've just started playing with Java 8 lambdas and I'm trying to implement some of the things that I'm used to in functional languages.</p>
  
  <p>For example, most functional languages have some kind of find function that operates on sequences, or lists that returns the first element, for which the predicate is <code>true</code>. The only way I can see to achieve this in Java 8 is:</p>
  
  <pre><code>lst.stream()
      .filter(x -&gt; x &gt; 5)
      .findFirst()
  </code></pre>
  
  <p>However this seems inefficient to me, as the filter will scan the whole list, at least to my understanding (which could be wrong). Is there a better way?  </p>