Use fold to find the mode of any list in Kotlin

前端 未结 0 1659
伪装坚强ぢ
伪装坚强ぢ 2020-12-04 20:59

Is there a possible way to find the mode from the fold?

Code

var numbers = listOf(9,3,7,6,6,6,11,11,6,3)

var answer = numbers.fold().

相关标签:
回答
  • 消灭零回复
提交回复
热议问题