내부 반복과 외부 반복 그리고 중간 연산과 최종 연산 #48
Unanswered
coalong
asked this question in
CHAPTER 4 스트림 소개 - Q&A
Replies: 1 comment
-
그렇지 않나요? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Q. 스트림 API 의 최종 연산인
forEach
와count
,collect
등 은 외부 동작이고,중간 연산인
filter
,map
,limit
,sorted
,distinct
등 중간 연산은 내부 동작이라고 볼 수 있는 것일까??(아래 그림처럼)
그렇다면, 최종 연산(외부 연산)을 하게 되면서 스트림(커다란 하나의 흐름?)이 끝나기 때문에 스트림 API 의 일회성 이 나타나는 건지?
Beta Was this translation helpful? Give feedback.
All reactions