Skip to content
This repository was archived by the owner on Aug 28, 2025. It is now read-only.

Commit c0895fe

Browse files
author
von-steinkirch
committed
quick fix: use import from basics on proofs
1 parent 8c93f77 commit c0895fe

File tree

2 files changed

+25
-6
lines changed

2 files changed

+25
-6
lines changed

README.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,8 +114,31 @@ theorem double_add (n m : Nat) : double (n + m) = double n + double m := by
114114

115115
<br>
116116

117+
run all `*.lean` files with:
118+
117119
```shell
118120
make build
121+
122+
info: src/Basics.lean:8:0: 43 :
123+
info: src/Basics.lean:9:0: 44
124+
info: src/Basics.lean:12:0: Bool.true : Bool
125+
info: src/Basics.lean:13:0: false
126+
info: src/Basics.lean:16:0: "gm, anon" : String
127+
info: src/Basics.lean:17:0: "gm, anon"
128+
info: src/Basics.lean:27:0: 666
129+
info: src/Basics.lean:32:0: true
130+
info: src/Basics.lean:33:0: false
131+
ℹ [2853/2855] Built src.SimpleProofs_I
132+
info: src/SimpleProofs_I.lean:21:0: 10
133+
info: src/SimpleProofs_I.lean:22:0: 0
134+
info: src/SimpleProofs_I.lean:23:0: 6
135+
info: src/SimpleProofs_I.lean:26:0: true
136+
info: src/SimpleProofs_I.lean:27:0: false
137+
info: src/SimpleProofs_I.lean:28:0: true
138+
info: src/SimpleProofs_I.lean:31:0: double_add (n m : ℕ) : double (n + m) = double n + double m
139+
info: src/SimpleProofs_I.lean:34:0: 14
140+
info: src/SimpleProofs_I.lean:35:0: 14
141+
Build completed successfully.
119142
```
120143

121144
<br>

src/SimpleProofs_I.lean

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,9 @@
1+
import src.Basics
2+
13
/-!
24
## simple proofs I
35
-/
46

5-
-- takes a natural number and returns its double
6-
def double (n : Nat) : Nat := n + n
7-
8-
-- checks if a number is even by seeing if it's divisible by 2
9-
def isEven (n : Nat) : Bool := n % 2 = 0
10-
117
-- this theorem proves that doubling the sum of two numbers is the same as
128
-- adding their doubles --> 2(n + m) = 2n + 2m
139

0 commit comments

Comments
 (0)