하지만 새 줄 문자가 줄 끝에 있건 없건 아무 문제가 없다고 자신하기 때문에 조용히 이대로 계
속 진행한다.
코틀린 표준 라이브러리에 정의되었어야 한다고 생각하지만 들어있지는 않은
Writer
::
appendLines
확장 함수 안에 이터레이션을 감추면, 마치 루프를 돌지 않는 척 할
수 있다.
예제
20.24
[
io
-
to
-
data
.
15
:
src
/
main
/
java
/
travelator
/
marketing
/
HighValueCustomersMain
.
kt
]
fun main() {
System.`in`.reader().use { reader ->
System.out.writer().use ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month, and much more.