lean2/tests/lean/run/let_tac.lean
Sebastian Ullrich 2185ee7e95 feat(library/tactic): make let tactic transparent, introduce new opaque note tactic
The new let tactic is semantically equivalent to let terms, while `note`
preserves its old opaque behavior.
2015-12-14 10:14:02 -08:00

21 lines
350 B
Text

import data.nat
open algebra
example (a b : Prop) : a → b → a ∧ b :=
begin
intro Ha, intro Hb,
let Ha' := Ha,
let Hb' := Hb,
let aux := and.intro Ha Hb,
exact aux
end
open nat
example (a b : nat) : a > 0 → b > 0 → a + b + 0 > 0 :=
begin
intro agt0, intro bgt0,
let H := add_pos agt0 bgt0,
change a + b > 0,
exact H
end