Stream of a reverse list
Joe Bowbeer
joe.bowbeer at gmail.com
Mon Jul 15 06:28:44 PDT 2013
It seems like overkill to add a specific method for what is likely to be a
general problem, but it's not clear to me what the best general solution
is...
One option is to create an IntStream of reversed indices, using iterate(),
then map that to a stream of elements.
Can generate() be used in this situation to generate the reversed stream
directly?
--Joe
On Jul 15, 2013 2:41 AM, "Remi Forax" <forax at univ-mlv.fr> wrote:
> How to get a stream of a list in reverse order without actually reversing
> the list ?
>
> do we need a List.reverseStream() or there is another way ?
>
> Rémi
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/lambda-libs-spec-experts/attachments/20130715/449d41d1/attachment.html
More information about the lambda-libs-spec-experts
mailing list