2015-05-02 22:48:25 +00:00
|
|
|
open nat
|
|
|
|
|
|
|
|
example (a : nat) : a + 0 = a :=
|
|
|
|
by reflexivity
|
|
|
|
|
|
|
|
example (a : Prop) : a ↔ a :=
|
|
|
|
by reflexivity
|
|
|
|
|
|
|
|
example (a b : Prop) : (a ↔ b) → (b ↔ a) :=
|
|
|
|
by intros; symmetry; assumption
|
|
|
|
|
|
|
|
example (a b c : nat) : a = b → b = c → c = a :=
|
|
|
|
begin
|
|
|
|
intros,
|
|
|
|
symmetry,
|
|
|
|
transitivity b,
|
2015-05-03 00:32:03 +00:00
|
|
|
repeat assumption
|
2015-05-02 22:48:25 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
example (a b c : Prop) : (a ↔ b) → (b ↔ c) → (c ↔ a) :=
|
|
|
|
begin
|
|
|
|
intros,
|
|
|
|
symmetry,
|
|
|
|
transitivity b,
|
2015-05-03 00:32:03 +00:00
|
|
|
repeat assumption
|
2015-05-02 22:48:25 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
example {A B C : Type} (a : A) (b : B) (c : C) : a == b → b == c → c == a :=
|
|
|
|
begin
|
|
|
|
intros,
|
|
|
|
symmetry,
|
|
|
|
transitivity b,
|
2015-05-03 00:32:03 +00:00
|
|
|
repeat assumption
|
2015-05-02 22:48:25 +00:00
|
|
|
end
|