2021年3月14日

摘要: fun test11(){ var result = Result("success",4) val (msg,code) = result println("Message:$msg") println("Code:$code") } 阅读全文
posted @ 2021-03-14 22:16 endian11 阅读(51) 评论(0) 推荐(0) 编辑
摘要: val list = listOf(1,2,3)val listStr = listOf("1","2",'3')val reuslt = list.sum { println("it:${it}") }println("result:${reuslt}") /** * 高阶函数 函数作为参数 */ 阅读全文
posted @ 2021-03-14 22:09 endian11 阅读(40) 评论(0) 推荐(0) 编辑

导航