Fixpoint before {A: Type} (x : A) y l : Prop :=
  match l with
    | [] => False
    | a :: l' =>
      a = x \/
      (a <> y /\ before x y l')
  end.

Lemma before_split : forall l (x y : A), before x y l -> x <> y -> In x l -> In y l -> exists xs ys zs, l = xs ++ x :: ys ++ y :: zs.