<@U3RE3RVLJ> If I get your code correctly, `curren...
# announcements
m
@ziggy42 If I get your code correctly,
currentTotal
is always equal to the final
before
, right? so
Copy code
val list = some.things.map { 
    Something.fromOtherThing(it, currentTotal, currentTotal - it.amount).also {
            currentTotal -= it.amount
    }
}
val currentTotal = list.last().thirdParameter
should work
z
so cool! thanks