let mem h key = let rec mem_in_bucket = function | Empty -> false | Cons(k, d, rest) -> compare k key = 0 || mem_in_bucket rest in mem_in_bucket h.data.((hash key) mod (Array.length h.data))