let
rec
cardinal =
function
Empty
->
0
|
Node
(l, v, r, _)
->
cardinal l + 1 + cardinal r