vault backup: 2023-10-02 15:03:09

This commit is contained in:
2023-10-02 15:03:09 +02:00
parent 8d5cfa14dc
commit 9319ab68cd
4 changed files with 55 additions and 25 deletions

View File

@ -87,7 +87,7 @@ _: int list = [1 ; 2 ; 3; 4]
## List manipulation
### Traverse
Sequential traverse have to solution, first is the list is empty, then you stop. Else if the list is not empty, we treat the head
Sequential traverse have to solution, first is the list is empty, then you stop. Else if the list is not empty, we extract the head and the tail, we treat the head and we traverse the trail (rec call)
```Ocaml
# let p = (1, 2);;
val p: int*int = (1,2)