proposition: Theorem le_inv : forall a n b a' n' b', leq lt (cons a n b) (cons a' n' b') -> lt a a' \/ a = a' /\ (n < n')%nat \/ a = a' /\ n = n' /\ leq lt b b'.
proof: Proof. intros a n b a' n' b' H; rewrite le_lt_eq in *. destruct H. - apply lt_inv in H; intuition. - injection H; intuition. Qed.
imports: Coq(Arith Max Bool Lia Compare_dec Relations Ensembles Wellfounded Bool RelationClasses Operators_Properties ArithRing Logic.Eqdep_dec) hydras(More_Arith Restriction DecPreOrder) hydras(OrdNotations)