Description
Many software developers have written a Python program without explicitly declaring the types of the parameters for a function's parameters or return values. Since the Python programming language now supports type annotations, many people in the community are exploring this way to describe the data that a function accepts as input and produces as output. When you start to apply Python's type annotations, their syntax and meaning can be confusing and it is common to wonder whether or not there is any benefit to adding them at all!
This presentation will introduce Python's type annotations by iteratively applying them to a function that does not have explicit types. After explaining how to use the types available in the typing package, this talk will illustrate the ways in which a static type checker like mypy can find bugs in a Python program before it is executed. People who watch this talk will gain the knowledge they need to start writing their first type annotations, use them to improve their Python programs, and ultimately find them to be beneficial.