New Python Type hints offers type checking on to function parameters, return values, class attributes, as if it's a static typed language.
Python is known as a dynamic, strong-typed language. Most developers love it but some feel mad without type checking or type-hinted auto-completion. In Python3.5, Type Hints is introduced to further delight developers who want those features.
Type Hints offers type checking on function parameters, return values and class attributes, as if it’s static-typed. If you pass something does not match the expected type, a warning will be given.
According to The Theory of Type Hints, we wrote a blog to show examples on how the rules work out in practice: