diff --git a/stdlib/ktSrc/JavaIterables.kt b/stdlib/ktSrc/JavaIterables.kt index f6996b7d989..d299d6485a6 100644 --- a/stdlib/ktSrc/JavaIterables.kt +++ b/stdlib/ktSrc/JavaIterables.kt @@ -85,7 +85,7 @@ inline fun java.lang.Iterable.foreach(operation: (element: T) -> Unit) { * Folds all the values from from left to right using the initial value to perform the operation on sequential pairs of values * * For example to sum together all numeric values in a collection of numbers it would be - * {code}numbers.fold(0){(a, b) -> a + b}{code} + * {code}val total = numbers.fold(0){(a, b) -> a + b}{code} */ inline fun java.lang.Iterable.fold(initial: T, operation: (it: T, it2: T) -> T): T { var answer = initial