diff options
author | Camil Staps | 2016-02-02 19:24:50 +0100 |
---|---|---|
committer | Camil Staps | 2016-02-02 19:24:50 +0100 |
commit | a7d7542dc646a5fd124ef71e71ce260889f1701b (patch) | |
tree | 04ed89503bbb3cc9933273a1326a53ca724c3492 /1415/files/practicum/EersteOfLaatste.icl | |
parent | week6 camil: working positioning of lines by putting empties at left and righ... (diff) |
Diffstat (limited to '1415/files/practicum/EersteOfLaatste.icl')
-rw-r--r-- | 1415/files/practicum/EersteOfLaatste.icl | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/1415/files/practicum/EersteOfLaatste.icl b/1415/files/practicum/EersteOfLaatste.icl new file mode 100644 index 0000000..bb02c4c --- /dev/null +++ b/1415/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)
+*/
|