Est-ce qu'une bonne volonté pourrait me confirmer (ou me corriger) cette réponse :

Code OCaml : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
    (* Okasaki, Exercise 3.2 page 19 *)
    let insert x = function
        | Empty -> singleton x
        | Node(_,y,a2,b2) as h2 ->
            if Less.than x y then Node(1,x,h2,Empty) (* make_tree x Empty h2 *)
            else make_tree y a2 (merge (singleton x) b2)

Pour l'exercice 3.2 page 19 du livre.