LongStream sequential() returns a sequential LongStream. It may return itself, either because the stream was already sequential, or because the underlying stream state was modified to be sequential. LongStream sequential() is an intermediate operation. Intermediate operations are invoked on a Stream instance and after they finish their processing, they give a Stream instance as output.
LongStream sequential() Where, LongStream is a sequence of primitive long-valued element.
Example 1 :
3 5 9 12 14
Example 2 :
-2 -1 0 1 2 3
- IntStream sequential() in Java
- DoubleStream sequential() in Java
- Creating Sequential Stream from an Iterator in Java
- LongStream sum() in Java
- LongStream of() in Java
- LongStream max() in Java with examples
- LongStream skip() in Java
- LongStream iterator() in Java
- LongStream sorted() in Java
- LongStream concat() in Java
- LongStream findFirst() in Java
- LongStream summaryStatistics() in Java
- LongStream range() in Java
- LongStream mapToDouble() in Java
- LongStream rangeClosed() in Java
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.