aboutsummaryrefslogtreecommitdiff
path: root/sem7/pp
diff options
context:
space:
mode:
Diffstat (limited to 'sem7/pp')
-rw-r--r--sem7/pp/lec5.hs9
1 files changed, 9 insertions, 0 deletions
diff --git a/sem7/pp/lec5.hs b/sem7/pp/lec5.hs
new file mode 100644
index 0000000..246c85a
--- /dev/null
+++ b/sem7/pp/lec5.hs
@@ -0,0 +1,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