Mathematicians' favourite shorthand 'iff' dates only from 1955
The four-letter word 'iff', meaning 'if and only if', first appeared in print in John L. Kelley's General Topology in 1955. Paul Halmos usually gets the credit for inventing it, though he admitted he could never quite believe he was really the first. Nobody has fully agreed how to pronounce it, either.
Logicians call the idea a biconditional. 'P if and only if Q' is true in exactly two situations: when both statements are true, or when both are false. It combines 'P only if Q', which is the familiar 'if P then Q', with its converse, 'P if Q'. Ordinary 'if' leaves room for P to be true without Q; adding 'only if' closes that gap. Writers express the same link with phrases such as 'necessary and sufficient', 'precisely when' or 'just in case', and in digital circuits it matches the output of an XNOR gate, the opposite of XOR.
Proving such a statement usually means proving two directions: that P leads to Q and that Q leads to P, or alternatively that P leads to Q and not-P leads to not-Q. Drawn as Euler diagrams, 'P only if Q' puts P inside Q, while 'if and only if' makes the two circles identical.
Pronunciation remains a small puzzle. Most people simply read 'iff' aloud as the full four words. Kelley used it where, in his words, 'euphony demands something less', and one discrete mathematics textbook recommends lingering on the double f so listeners can hear the difference from plain 'if'. Mathematical definitions add another wrinkle: most texts write just 'if' in a definition, trusting readers to understand it as 'if and only if'.
The idea matters beyond pure logic. Russell and Norvig's artificial intelligence textbook notes that databases and logic programs often treat their contents as all and only the relevant facts, so 'Richard has two brothers, Geoffrey and John' needs no extra clause ruling out a third. That assumption mirrors the legal principle that expressly mentioning one thing excludes all others, and supports the use of logic programming to model laws.
Source: If and only if