Definition exists_witness (f : SS.elt -> bool) (s : SS.t) : option SS.elt :=
SS.choose (SS.filter f s).

(* Specifications: *)
Lemma exists_witness_ok : forall e f s,
Proper (S.Equal ==> eq) f ->
exists_witness f s = Some e -> SS.In e s.
Lemma exists_witness_ok : forall e f s,
Proper (S.Equal ==> eq) f ->
exists_witness f s = Some e -> SS.In e s.