Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix broken code example (#138) #142

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions induction_and_recursion.md
Original file line number Diff line number Diff line change
Expand Up @@ -598,7 +598,7 @@ def listAdd [Add α] : List α → List α → List α

You are encouraged to experiment with similar examples in the exercises below.

Local recursive declarations
Local Recursive Declarations
---------

You can define local recursive declarations using the `let rec` keyword.
Expand Down Expand Up @@ -633,7 +633,7 @@ theorem length_replicate (n : Nat) (a : α) : (replicate n a).length = n := by
: (replicate.loop a n as).length = n + as.length := by
match n with
| 0 => simp [replicate.loop]
| n+1 => simp [replicate.loop, aux n, Nat.add_succ, Nat.succ_add]
| n+1 => simp [replicate.loop, aux n, Nat.add_assoc, Nat.succ_add]
exact aux n []
```

Expand All @@ -655,7 +655,7 @@ where
: (replicate.loop a n as).length = n + as.length := by
match n with
| 0 => simp [replicate.loop]
| n+1 => simp [replicate.loop, aux n, Nat.add_succ, Nat.succ_add]
| n+1 => simp [replicate.loop, aux n, Nat.add_assoc, Nat.succ_add]
```

Well-Founded Recursion and Induction
Expand Down