Definition interv : Type := (Z * Z)%type.(** * Membership *)

Definition In (x: Z) (i: interv) : Prop := fst i <= x < snd i.

(* Specifications: *)
Lemma In_dec: forall x i, {In x i} + {~In x i}.
Lemma notin_range: forall x i, x < fst i \/ x >= snd i -> ~In x i.
Lemma range_notin: forall x i, ~In x i -> fst i < snd i -> x < fst i \/ x >= snd i.