Protocol extensions

Protocols can be extended to provide method implementations to conforming types, allowing us to define behavior on protocols themselves, rather than in each type's conformance. In this post, Dmitrii Ivanov looks at how protocol extensions are used to add default implementations and additional functionality.