Section Count.
Variable (X : eqType).
Definition count (n : nat) (x : X) (xs : t X n) :=
fold_right (fun y c => if Dec (x = y) then S c else c) xs 0.

Lemma count0_notIn' (n : nat) (x : X) (xs : t X n) :
~ In x xs -> count x xs = 0.