Files
lean-pl-tutorials/README.md

49 lines
1.7 KiB
Markdown

# Lean 4 + Programming Language Semantics
A self-study curriculum for computer scientists who know PL theory and want
to mechanize proofs in Lean 4 — from syntax to soundness of the
Hindley-Milner type system.
## Structure
```
├── README.md ← this file
├── tutorial-01-basics/ ← Lean 4 fundamentals
│ ├── 01-types-and-functions.md
│ ├── 02-inductive-types.md
│ ├── 03-propositions-and-proofs.md
│ ├── 04-quantifiers-and-equality.md
│ ├── 05-advanced-tactics.md
│ ├── 06-structures-type-classes.md
│ └── 07-dependent-types.md
├── tutorial-02-semantics/ ← PL semantics in Lean
│ ├── 08-syntax-representation.md
│ ├── 09-substitution.md
│ ├── 10-small-step-semantics.md
│ ├── 11-stlc-type-system.md
│ ├── 12-type-safety.md
│ ├── 13-hm-declarative.md
│ ├── 14-algorithm-w.md
│ └── 15-soundness-completeness.md
└── references.md ← all cited resources
```
## How to Use
1. Install Lean 4 (VS Code + `lean4` extension):
[lean-lang.org/lean4/doc/quickstart.html](https://lean-lang.org/lean4/doc/quickstart.html)
2. Start with **Tutorial 1**, Unit 1. Each unit is a standalone `.md` file with
inline Lean exercises.
3. Type the exercises into a `.lean` file and make it compile.
4. After Tutorial 1, move to **Tutorial 2** to mechanize STLC and HM.
## Prerequisites
- Functional programming (Haskell/OCaml familiarity)
- Basic PL theory (lambda calculus, operational semantics, type systems)
- No prior proof assistant experience required
## References
See [references.md](references.md) for the full list of resources.