let max_sub_hom2 e s =
let m = ref 0 in
let n = ref 0 in
let len = Array.length s in
for i = 1 to len - 1 do
if (s.(i-1) = e) then (
incr n;
if (s.(i) <> e) then (m := max !m !n; n := 0)
)
done;
if (len > 0) && (s.(len - 1) = e) then (incr n; m := max !m !n);
!m