可以在Kotlin中进行类似于Python的参数解包吗?例如.
>>> a = [1,2,3]
>>> b = [*a,4,5,6]
>>> b
[1, 2, 3, 4, 5, 6]
I know that it is possible in Kotlin as follows:
>>> listOf(1, 2, 3, *listOf(4,5,6).toTypedArray())
[1, 2, 3, 4, 5, 6]
感觉在Kotlin 有更简单的方法.有什么 idea 吗?