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