跳到內容

99 Elm 問題/問題 28

來自 Wikibooks,面向開放世界的開放書籍

對列表列表排序。28.a) 根據子列表長度對列表列表排序 28.b) 根據元素長度頻率對該列表元素排序;即,具有罕見長度的列表排在前面,具有更頻繁長度的列表排在後面。

# # # 這是一個存根 # # #

Example in Elm:
import Html exposing (text)
import List

f : Int -> Int
-- your implementation goes here

main = text (toString (f 0))

結果

4

解決方案

華夏公益教科書