Proposition algebra and short-circuit logic Jan A. Bergstra and Alban Ponse Section Theory of Computer Science Informatics Institute, Faculty of Science University of Amsterdam, The Netherlands www.science.uva.nl/{ ~ janb/, ~ alban/} Abstract. Short-circuit evaluation denotes the semantics of proposi- tional connectives in which the second argument is only evaluated if the first argument does not suffice to determine the value of the expression. In programming, short-circuit evaluation is widely used. We review proposition algebra [2010], an algebraic approach to proposi- tional logic with side effects that models short-circuit evaluation. Propo- sition algebra is based on Hoare’s conditional [1985], which is a ternary connective comparable to if-then-else. Starting from McCarthy’s notion of sequential evaluation [1963] we discuss a number of valuation con- gruences on propositional statements and we introduce Hoare-McCarthy algebras as the structures that model these congruences. We also briefly discuss the associated short-circuit logics, i.e., the logics that define these congruences if one restricts to sequential binary connectives. Key words: Conditional composition, reactive valuation, sequential con- nective, short-circuit evaluation, side effect. 1 Introduction Short-circuit evaluation is a folk term 1 that describes how the common propo- sitional connectives are evaluated in a setting of programming languages: eval- uation stops as soon as the value T (true ) or F (false ) of the expression is determined. In particular, the “conjunction” of x and y in a notation commonly used to prescribe short-circuit evaluation, is often explained by the identity x && y = if x then y else F, and the connective or in short-circuit interpretation, notation || , is then ex- plained by the identity x || y = if x then T else y. So, evaluation of x && y stops if x yields F and then y is not evaluated, and similarly, evaluation of x || y stops if x yields T and then y is not evaluated. In the most general case, both && and || are not commutative. 1 Other names used for short-circuit evaluation are Minimal evaluation and McCarthy evaluation.