Well-formed formula

In logic, WFF (pronounced "wiff") is an abbreviation for well-formed formula. Given a formal grammar, a WFF is any string that is generated by that grammar. To say that a string $$\ S$$ is a WFF with respect to a given formal grammar $$\ G$$ is equivalent to saying that $$\ S$$ belongs to the language generated by $$\ G$$, i.e. $$S \in \boldsymbol{L}(G)$$.

In formal logic, proofs are sequences of WFFs with certain properties, and the final WFF in the sequence is what is proven.

Example
The well-formed formulae of the propositional calculus $$\mathcal{L}$$ are defined by the following formal grammar, written in BNF:


 * ::= p | q | r | s | t | u | ... (arbitrary finite set of propositional variables)
 * ::= | $$\neg$$ | ( $$\wedge$$ ) | ( $$\vee$$ ) | ( $$\rightarrow$$ ) | ( $$\leftrightarrow$$ )

The sequence of symbols


 * (((p $$\rightarrow$$ q) $$\wedge$$ (r $$\rightarrow$$ s)) $$\wedge$$ ($$\neg$$q $$\vee$$ $$\neg$$s))

is a WFF because it is grammatically correct. The sequence of symbols


 * ((p $$\rightarrow$$ q)$$\rightarrow$$(qq))p))

is not a WFF, because it does not conform to the grammar of $$\mathcal{L}$$.

Trivia
WFF is part of an esoteric pun used in the name of "WFF 'N PROOF: The Game of Modern Logic," by Layman Allen, developed while he was at Yale Law School (he was later a professor at the University of Michigan). The suite of games is designed to teach the principles of symbolic logic to children (in Polish notation). Its name is a pun on whiffenpoof, a nonsense word used as a cheer at Yale University made popular in The Whiffenpoof Song and The Whiffenpoofs.