2014-11-30 21:16:01 -08:00
|
|
|
import logic
|
2014-10-20 15:26:16 -07:00
|
|
|
open tactic
|
|
|
|
|
|
|
|
theorem tst1 (a b : Prop) : a → b → b :=
|
2014-10-22 16:15:00 -07:00
|
|
|
by intro Ha; intro Hb; apply Hb
|
2014-10-20 15:26:16 -07:00
|
|
|
|
|
|
|
theorem tst2 (a b : Prop) : a → b → a ∧ b :=
|
2015-04-27 15:06:16 -07:00
|
|
|
by intro Ha; intro Hb; apply and.intro; apply Ha; apply Hb
|
2014-10-20 15:26:16 -07:00
|
|
|
|
|
|
|
theorem tst3 (a b : Prop) : a → b → a ∧ b :=
|
|
|
|
begin
|
2014-10-22 16:15:00 -07:00
|
|
|
intro Ha,
|
|
|
|
intro Hb,
|
2014-10-20 15:26:16 -07:00
|
|
|
apply and.intro,
|
2014-10-22 18:11:09 -07:00
|
|
|
apply Ha,
|
2014-10-20 15:26:16 -07:00
|
|
|
apply Hb,
|
|
|
|
end
|
|
|
|
|
|
|
|
theorem tst4 (a b : Prop) : a → b → a ∧ b :=
|
|
|
|
begin
|
2015-03-27 17:26:06 -07:00
|
|
|
intros [Ha, Hb],
|
2015-04-27 15:06:16 -07:00
|
|
|
apply and.intro,
|
|
|
|
apply Ha,
|
2014-10-20 15:26:16 -07:00
|
|
|
apply Hb,
|
|
|
|
end
|
|
|
|
|
|
|
|
theorem tst5 (a b : Prop) : a → b → a ∧ b :=
|
|
|
|
begin
|
|
|
|
intros,
|
|
|
|
apply and.intro,
|
|
|
|
eassumption,
|
|
|
|
eassumption
|
|
|
|
end
|