aboutsummaryrefslogtreecommitdiff
path: root/sem7/pp/lec5.hs
blob: 246c85a1d68a099b45fdaf99a2d1da4569efe718 (plain)
1
2
3
4
5
6
7
8
9
-- Opgaver før lecture
sum' 0 = 0
sum' x = x + sum' (x-1)

flip' = map (\(x, y) -> (y, x))
-- Here i would guess that the type is [(a, b)] -> [(b, a)]
-- When quering i get flip' :: [(b, a)] -> [(a, b)]
-- Yeah they are the same