Fixpoint revflatten {A: Type} (xss: list (list A)) : list A :=
match xss with
| []       => []
| xs::xss' => revflatten xss' ++ xs
end.

Lemma count_occ_remove_O A eq_dec (a: A) l :
count_occ eq_dec (remove eq_dec a l) a = 0.