<gh_stars>1-10
module DupChanExample where

import Control.Concurrent.Chan
import Control.Concurrent (forkIO)

client_thread name input output = do
  value <- readChan input
  writeChan output ("Thread "++name++" saw value "++value++".")

-- infinite loop
forever m = m >> forever m

-- this will print one or other of:
-- "Thread unicast left saw value ham.", or: