Explain why the Curry-Howard correspondence works with constructive (intuitionistic) logic rather than classical logic, and what this means for the law of excluded middle.
Think about your answer, then reveal below.
Model answer: The correspondence naturally aligns with constructive logic because a proof of 'A or B' must provide either a proof of A or a proof of B (corresponding to constructing either a Left or Right value of a sum type). Classical logic's law of excluded middle (A or not A) would require a program that, for any proposition A, decides whether A is true or false — which is not computable in general. Classical reasoning can be recovered by adding axioms (corresponding to non-constructive language features like continuations), but the direct correspondence is with constructive logic.
This is not merely a technical limitation but a philosophical point. Constructive logic requires that existence claims be witnessed by explicit constructions: to prove 'there exists an x such that P(x)', you must produce a specific x. Under Curry-Howard, this means a proof of an existential is a pair (witness, proof), which is a dependent pair type. Classical logic allows proving existence without a witness (by contradiction), which has no direct computational interpretation. The Curry-Howard correspondence reveals that constructive logic IS computation.