interact package:bytestring
The interact function takes a function of type ByteString ->
ByteString as its argument. The entire input from the standard
input device is passed to this function as its argument, and the
resulting string is output on the standard output device.