且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

将数组转换为Kotlin中的列表

更新时间:2023-02-23 10:00:37

标准库中的Kotlin支持此转换.

Kotlin support in the standard library this conversion.

您可以直接使用

disableNos.toList()

或者如果您想使其可变:

or if you want to make it mutable:

disableNos.toMutableList()