当我对 Elm 的
什么是
List
进行排序时,使用了哪种排序算法?> sort [1,3,5,6]
[1,3,5,6] : [comparable]
什么是
[可比较的]
类型,如何将其转换为数字
?> [1,2]:: (sort [3,2,1])
[1 of 1] Compiling Repl ( repl-temp-000.elm )
Type error on line 4, column 3 to 24:
[1,2] :: (sort [3,2,1])
Expected Type: [number]
Actual Type: comparable
现在可能是了解Elm中List
实现的好时机,但我现在并不想问太深入的问题。只需让它运行起来。