Klitos Kyriacou
12/03/2024, 4:54 PMfor ((index, value) in list.withIndex()) // Correct: the class name is IndexedValue: index first, value second.
val (time, value) = measureTimedValue { } // Wrong! the class name is TimedValue, yet it's actually value first, time second.
Sam
12/03/2024, 4:57 PMPHondogo
12/03/2024, 5:00 PMokarm
12/03/2024, 5:05 PMIt's like a USB-A plug, whichever way I try first is always the wrong oneAnd like any other binary system, only the 3rd time works!
Michael de Kaste
12/04/2024, 10:34 AMIndexedValue
. but calling a function thats called withIndex
, I would assume it returns something with a value first, and then the index. because its a list of values, with index.David Kubecka
12/04/2024, 10:54 AMmeasureTimedValue
and was never bothered by the order of components. I would be more surprised by withIndex
, although I see now that it's at least consistent with mapIndexed
.CLOVIS
12/11/2024, 10:39 PM