mirror of
https://github.com/unisonweb/unison.git
synced 2024-09-11 10:35:57 +03:00
420 B
420 B
scratch/main> builtins.merge
-- List.map : (a -> b) -> [a] -> [b]
List.map f =
go acc = cases
[] -> acc
h +: t -> go (acc :+ f h) t
go []
scratch/main> add
scratch/main> view List.map
List.map2 : (g -> g2) -> [g] -> [g2]
List.map2 f =
unused = "just to give this a different hash"
go acc = cases
[] -> acc
h +: t -> go (acc :+ f h) t
go []