diff options
author | Mart Lubbers | 2015-02-06 08:39:37 +0100 |
---|---|---|
committer | Mart Lubbers | 2015-02-06 08:39:37 +0100 |
commit | 379b6353396ca2401241d714733d570629835ffe (patch) | |
tree | 26652c854a79c627b5f50bc8ac26f9b84f8e196d /files/practicum/EersteOfLaatste.icl | |
parent | Merge branch 'master' of https://github.com/dopefishh/fp1 (diff) |
added practicum files, updated gitignore
Diffstat (limited to 'files/practicum/EersteOfLaatste.icl')
-rw-r--r-- | files/practicum/EersteOfLaatste.icl | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/files/practicum/EersteOfLaatste.icl b/files/practicum/EersteOfLaatste.icl new file mode 100644 index 0000000..bb02c4c --- /dev/null +++ b/files/practicum/EersteOfLaatste.icl @@ -0,0 +1,37 @@ +implementation module EersteOfLaatste
+
+import StdEnv
+
+// 1.
+eerste2 :: [a] -> [a]
+eerste2 ...
+
+laatste2 :: [a] -> [a]
+laatste2 ...
+
+
+// 2.
+// Reduceer de volgende Start-regels met de hand:
+Start = hd (hd (hd [[[1,2,3],[4]],[[5],[6]]]))
+Start = hd (tl [1,2,3,4,5])
+Start = eerste2 [[1],[],[2,3],[4,5,6]]
+Start = laatste2 [[1],[],[2,3],[4,5,6]]
+
+
+// 3.
+eersten :: Int [a] -> [a]
+eersten ...
+
+laatsten :: Int [a] -> [a]
+laatsten ...
+
+// 4.
+// Maak de volgende beweringen af:
+/*
+Voor alle 0 <= n, xs :: [a] : eersten n (eersten n xs) =
+Voor alle 0 <= n, xs :: [a] : eersten n (laatsten n xs) =
+Voor alle 0 <= n, xs :: [a] : laatsten n (eersten n xs) =
+Voor alle 0 <= n, xs :: [a] : laatsten n (laatsten n xs) =
+Voor alle 0 <= m <= n, xs :: [a] : eersten m (eersten n xs) =
+Voor alle 0 <= m <= n, xs :: [a] : length (eersten m xs) ? length (eersten n xs)
+*/
|