...

/

Channels as Function Parameters

Channels as Function Parameters

Let’s learn how to use channels as function parameters.

Using a channel as a function parameter

When using a channel as a function parameter, we can specify its direction; that is, whether it is going to be used for sending or receiving data. If we know the purpose of a channel in advance, we should use this capability because ...