vault backup: 2023-10-25 17:27:14

This commit is contained in:
Louis Gallet 2023-10-25 17:27:14 +02:00
parent b1df54d806
commit fef0e7e66d
Signed by: lgallet
SSH Key Fingerprint: SHA256:qnW7pk4EoMRR0UftZLZQKSMUImbEFsiruLC7jbCHJAY
2 changed files with 3 additions and 20 deletions

View File

@ -33,24 +33,6 @@
} }
], ],
"currentTab": 1 "currentTab": 1
},
{
"id": "7734e3e697a0f69b",
"type": "tabs",
"children": [
{
"id": "4b8ef5548f793d6c",
"type": "leaf",
"state": {
"type": "markdown",
"state": {
"file": "Algo/Courses/Chapter 6 - Lists (Exercises).md",
"mode": "source",
"source": false
}
}
}
]
} }
], ],
"direction": "vertical" "direction": "vertical"

View File

@ -28,7 +28,7 @@ val sigma: (int -> int) -> int -> int = <fun>
``` ```
# let rec map f = function # let rec map f = function
| [] -> [] | [] -> []
|e::t -> f(e)::map f t ;; |e::t -> f e::map f t ;;
val map : ('a -> 'b) -> 'a list -> 'b list = <fun> val map : ('a -> 'b) -> 'a list -> 'b list = <fun>
``` ```
@ -36,4 +36,5 @@ val map : ('a -> 'b) -> 'a list -> 'b list = <fun>
``` ```
# let rec for_all p = function # let rec for_all p = function
| [] -> true | [] -> true
| e::t -> if p(e) then for_all p t else false;; | e::t -> if p e && for_all p t;;
val for_all: ('a -> bool) -> 'a list -> bool = <fun>