S SmartDocs
シリーズ: haskell haskell 4 行 · 更新日 2026-02-03

exercise_2_1.hs

haskell/Week_6_Lab/exercise_2_1.hs

-- Part of Exercise 2.1
-- Define a function that increments and sums elements of nested lists.
sumIncAll :: [[Integer]] -> [Integer]
sumIncAll xss = map (sum . map (+1)) xss

関連記事