Zulip Chat Archive

Stream: new members

Topic: How can I learn types?


İmran Tanrikolu (Aug 11 2025 at 18:24):

How can I learn and master dependent type theory and the propositions-as-types concept? Where can I find theories proven on Lean, from easy to advanced, to study? Which types do I need to learn and master for Lean?

Kenny Lau (Aug 11 2025 at 19:19):

these are rather broad questions, and this is just my advice, maybe I would start from (intuitionistic?) propositional logic (i.e. zeroth order), for example (i just made this up), try proving the following (i'll give you all the tools):

variable (P Q R : Prop)

#check And.intro
#check And.left
#check And.right

example (h₁ : P  Q) (h₂ : P) : Q :=
  h₁ h₂

theorem And.symm' (h : P  Q) : Q  P :=
  _

Kenny Lau (Aug 11 2025 at 19:19):

try to replace _ there with a correct term using the tools given

Kenny Lau (Aug 11 2025 at 19:20):

(it's also useful to look at the "expected type" window, which is by default collapsed on the website)

İmran Tanrikolu (Aug 11 2025 at 19:27):

Kenny Lau dedi:

(it's also useful to look at the "expected type" window, which is by default collapsed on the website)

Actually, what I mean is: where can I study type theory? It can be a book or another resource. Also, where can I find Lean proofs that I can study from simple to advanced?
I am currently learning and cannot fully write code myself yet. I am about to finish the Lean Number Game and looking for new resources.

Kenny Lau (Aug 11 2025 at 19:28):

https://leanprover.github.io/theorem_proving_in_lean4/#

Kenny Lau (Aug 11 2025 at 19:29):

people recommend this

İmran Tanrikolu (Aug 11 2025 at 19:32):

Kenny Lau dedi:

people recommend this

Thanks! By the way, do you have any recommendations on where I can find exercises and example problems? Any advice?

Kenny Lau (Aug 11 2025 at 19:36):

hmm, that's a good idea, we should have some exercises, i don't know if they exist

Kenny Lau (Aug 11 2025 at 19:36):

for now... i guess try to reproduce the book lol


Last updated: Dec 20 2025 at 21:32 UTC