Sleeping barber problem implemented in Haskell using STM