basic channel example
exercise 3.2
another solution of exercise 3.2