vault backup: 2023-10-30 10:07:22
This commit is contained in:
parent
493df09c4f
commit
3f39d3057c
29
.obsidian/workspace.json
vendored
29
.obsidian/workspace.json
vendored
@ -4,22 +4,31 @@
|
||||
"type": "split",
|
||||
"children": [
|
||||
{
|
||||
"id": "e2462eca75b6d8bf",
|
||||
"id": "f6fad86667169cdd",
|
||||
"type": "tabs",
|
||||
"children": [
|
||||
{
|
||||
"id": "f1000ea0f0e6db20",
|
||||
"id": "424b516a4faa9ad5",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "empty",
|
||||
"state": {}
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "ab0d8956c63542fc",
|
||||
"type": "leaf",
|
||||
"state": {
|
||||
"type": "markdown",
|
||||
"state": {
|
||||
"file": "Algo/Courses/Chapter 6 - Lists.md",
|
||||
"file": "Exam.md",
|
||||
"mode": "source",
|
||||
"source": false
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
],
|
||||
"currentTab": 1
|
||||
}
|
||||
],
|
||||
"direction": "vertical"
|
||||
@ -85,7 +94,7 @@
|
||||
"state": {
|
||||
"type": "backlink",
|
||||
"state": {
|
||||
"file": "Algo/Courses/Chapter 6 - Lists.md",
|
||||
"file": "Exam.md",
|
||||
"collapseAll": false,
|
||||
"extraContext": false,
|
||||
"sortOrder": "alphabetical",
|
||||
@ -102,7 +111,7 @@
|
||||
"state": {
|
||||
"type": "outgoing-link",
|
||||
"state": {
|
||||
"file": "Algo/Courses/Chapter 6 - Lists.md",
|
||||
"file": "Exam.md",
|
||||
"linksCollapsed": false,
|
||||
"unlinkedCollapsed": true
|
||||
}
|
||||
@ -125,7 +134,7 @@
|
||||
"state": {
|
||||
"type": "outline",
|
||||
"state": {
|
||||
"file": "Algo/Courses/Chapter 6 - Lists.md"
|
||||
"file": "Exam.md"
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -156,11 +165,12 @@
|
||||
"command-palette:Open command palette": false
|
||||
}
|
||||
},
|
||||
"active": "f1000ea0f0e6db20",
|
||||
"active": "ab0d8956c63542fc",
|
||||
"lastOpenFiles": [
|
||||
"Exam.md",
|
||||
"Algo/Courses/Chapter 6 - Lists.md",
|
||||
"Algo/Courses/Chapter 6 - Lists (Exercises).md",
|
||||
"Algo/Courses/Chapter 7 - High Order (exercises).md",
|
||||
"Algo/Courses/Chapter 6 - Lists.md",
|
||||
"Algo/Séminaire/Chapter 1 - CAML basics.md",
|
||||
"Algo/CM/CM du 04 octobre.md",
|
||||
"Code CAML.md",
|
||||
@ -201,7 +211,6 @@
|
||||
"Pasted image 20230912155138.png",
|
||||
"Algo/Chapter 0 - A bit of imperative/0.1 - Print.md",
|
||||
"Algo/Séminaire/Untitled",
|
||||
"Mathématiques/Séminaire/Logics/Logics.md",
|
||||
"Algo/Chapter 0 - A bit of imperative",
|
||||
"Algo/Séminaire/assets/69E2987C-209A-48CD-8964-5A60462966E5.jpg",
|
||||
"Untitled.canvas"
|
||||
|
16
Exam.md
Normal file
16
Exam.md
Normal file
@ -0,0 +1,16 @@
|
||||
## Multiple insertion
|
||||
```Ocaml
|
||||
let insert_mult n x lst =
|
||||
if n <= 0 then
|
||||
invalid_arg "insert_mult: n must be > 0"
|
||||
else
|
||||
match lst with
|
||||
| [] -> []
|
||||
| z::f ->
|
||||
let aux count = function
|
||||
| [] -> x
|
||||
| e::t ->
|
||||
if (count = n) then
|
||||
e :: x :: t
|
||||
else aux (count + 1) t
|
||||
in aux 1 t
|
Loading…
x
Reference in New Issue
Block a user