Co-Authored-By: Claude Sonnet 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017ic4b49nGy7tcEjVUa3WAA
12 lines
509 B
Plaintext
12 lines
509 B
Plaintext
rangeClosed(1,100).sum() : 5050
|
|
summaryStatistics : IntSummaryStatistics{count=8, sum=31, min=1, average=3.875000, max=9}
|
|
mapToInt(length).sum() : 17
|
|
average of empty IntStream : OptionalDouble.empty
|
|
sum of empty IntStream : 0
|
|
boxed().toList() : [1, 2, 3]
|
|
IntStream sum overflow : -2147483648
|
|
asLongStream sum : 2147483648
|
|
Math.addExact in long : no overflow
|
|
Math.addExact in int : integer overflow
|
|
Stream<Integer>.reduce sum : -2147483648 <- also wraps
|