public Optional<T> first(){
  Iterator<T> iterator=iterator();
  return iterator.hasNext() ? Optional.of(iterator.next()) : Optional.<T>empty();
}

public Optional < T > first ( ) { Iterator < T > iterator = iterator ( ) ; return iterator . hasNext ( ) ? Optional . of ( iterator . next ( ) ) : Optional . < T > empty ( ) ; }
convert an iterable stream into one first item of the stream .
