mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2025-04-27 07:33:57 +00:00
space before colon
This commit is contained in:
parent
fa0e3c632f
commit
9d2c2f37f4
@ -256,7 +256,7 @@ We now state Collatz conjecture. The proof is left as an exercise to the reader.
|
|||||||
def collatz_next (n : Nat) : Nat :=
|
def collatz_next (n : Nat) : Nat :=
|
||||||
if n % 2 = 0 then n / 2 else 3 * n + 1
|
if n % 2 = 0 then n / 2 else 3 * n + 1
|
||||||
|
|
||||||
def iter (k : Nat) (f: Nat → Nat) :=
|
def iter (k : Nat) (f : Nat → Nat) :=
|
||||||
match k with
|
match k with
|
||||||
| Nat.zero => fun x => x
|
| Nat.zero => fun x => x
|
||||||
| Nat.succ k' => fun x => f (iter k' f x)
|
| Nat.succ k' => fun x => f (iter k' f x)
|
||||||
|
Loading…
Reference in New Issue
Block a user