I need to keep a buffer of 100,000 integer samples in a Kotlin program and pass it between a few functions. I can declare it as Array<Int>, IntArray, List<Int> or MutableList<Int>, and they all seem to work with for loops and map.
What are the real differences in memory, mutability and type behaviour, and is a List declared with val actually immutable?




