lean4-htt/tests/lean/run/cute_binders.lean
2017-03-09 18:41:19 -08:00

17 lines
533 B
Text
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

definition range (lower : nat) (upper : nat) : set nat :=
λ a, lower ≤ a ∧ a ≤ upper
local notation `[` L `, ` U `]` := range L U
variables s : set nat
variables p : nat → nat → Prop
-- #check a ∈ s
set_option pp.binder_types true
#check ∀ b c a ∈ s, a + b + c > 0
-- ∀ (b c a : ), b ∈ s → c ∈ s → a ∈ s → a + b + c > 0 : Prop
#check ∀ a < 5, p a (a+1)
-- ∀ (a : ), a < 5 → p a (a + 1) : Prop
#check ∀ a b ∈ [2, 3], p a b
-- ∀ (a b : ), a ∈ [2, 3] → b ∈ [2, 3] → p a b