If you ever wondered how are types different from sets or more generally what is the difference between type theory and set theory, I recommend watching a talk by Thorsten Altenkirch at Foundations of Mathematics: Univalent Foundations and Set Theory 2016.