Definition checkPrf (f p : nat) : nat :=
  switchPR (wellFormedFormula f) (checkPrfHelp (cPair f p)) 0.

Lemma checkPrfCorrect2 : forall n m : nat, checkPrf n m <> 0 -> exists f : Formula, codeFormula L codeF codeR f = n /\ (exists l : list Formula, (exists p : Prf l f, codePrf L codeF codeR l f p = m)).